Skip to content

Commit

Permalink
Bug 1285212 - Add tooltips to permissions icons in the url bar. r=dao
Browse files Browse the repository at this point in the history
MozReview-Commit-ID: Lq6fCdQtN0P
  • Loading branch information
Johann Hofmann committed Aug 23, 2016
1 parent f4e4e38 commit b61a85e
Show file tree
Hide file tree
Showing 2 changed files with 47 additions and 43 deletions.
45 changes: 22 additions & 23 deletions browser/base/content/browser.xul
Original file line number Diff line number Diff line change
Expand Up @@ -691,56 +691,55 @@
consumeanchor="identity-box"
onclick="PageProxyClickHandler(event);"/>
<image id="sharing-icon" mousethrough="always"/>
<box id="blocked-permissions-container" align="center" tooltiptext="">
<box id="blocked-permissions-container" align="center">
<image data-permission-id="geo" class="blocked-permission-icon geo-icon" role="button"
aria-label="&urlbar.geolocationNotificationAnchor.label;"/>
tooltiptext="&urlbar.geolocationBlocked.tooltip;"/>
<image data-permission-id="desktop-notification" class="blocked-permission-icon desktop-notification-icon" role="button"
aria-label="&urlbar.webNotsNotificationAnchor3.label;"/>
tooltiptext="&urlbar.webNotificationsBlocked.tooltip;"/>
<image data-permission-id="camera" class="blocked-permission-icon camera-icon" role="button"
aria-label="&urlbar.webRTCShareDevicesNotificationAnchor.label;"/>
tooltiptext="&urlbar.cameraBlocked.tooltip;"/>
<image data-permission-id="indexedDB" class="blocked-permission-icon indexedDB-icon" role="button"
aria-label="&urlbar.indexedDBNotificationAnchor.label;"/>
tooltiptext="&urlbar.indexedDBBlocked.tooltip;"/>
<image data-permission-id="microphone" class="blocked-permission-icon microphone-icon" role="button"
aria-label="&urlbar.webRTCShareMicrophoneNotificationAnchor.label;"/>
tooltiptext="&urlbar.microphoneBlocked.tooltip;"/>
<image data-permission-id="screen" class="blocked-permission-icon screen-icon" role="button"
aria-label="&urlbar.webRTCShareScreenNotificationAnchor.label;"/>
tooltiptext="&urlbar.screenBlocked.tooltip;"/>
</box>
<box id="notification-popup-box"
hidden="true"
tooltiptext=""
onmouseover="document.getElementById('identity-icon').classList.add('no-hover');"
onmouseout="document.getElementById('identity-icon').classList.remove('no-hover');"
align="center">
<image id="default-notification-icon" class="notification-anchor-icon" role="button"
aria-label="&urlbar.defaultNotificationAnchor.label;"/>
tooltiptext="&urlbar.defaultNotificationAnchor.tooltip;"/>
<image id="geo-notification-icon" class="notification-anchor-icon geo-icon" role="button"
aria-label="&urlbar.geolocationNotificationAnchor.label;"/>
tooltiptext="&urlbar.geolocationNotificationAnchor.tooltip;"/>
<image id="addons-notification-icon" class="notification-anchor-icon install-icon" role="button"
aria-label="&urlbar.addonsNotificationAnchor.label;"/>
tooltiptext="&urlbar.addonsNotificationAnchor.tooltip;"/>
<image id="indexedDB-notification-icon" class="notification-anchor-icon indexedDB-icon" role="button"
aria-label="&urlbar.indexedDBNotificationAnchor.label;"/>
tooltiptext="&urlbar.indexedDBNotificationAnchor.tooltip;"/>
<image id="login-fill-notification-icon" class="notification-anchor-icon login-icon" role="button"
aria-label="&urlbar.loginFillNotificationAnchor.label;"/>
tooltiptext="&urlbar.loginFillNotificationAnchor.tooltip;"/>
<image id="password-notification-icon" class="notification-anchor-icon login-icon" role="button"
aria-label="&urlbar.passwordNotificationAnchor.label;"/>
tooltiptext="&urlbar.passwordNotificationAnchor.tooltip;"/>
<image id="plugins-notification-icon" class="notification-anchor-icon plugin-icon" role="button"
aria-label="&urlbar.pluginsNotificationAnchor.label;"/>
tooltiptext="&urlbar.pluginsNotificationAnchor.tooltip;"/>
<image id="web-notifications-notification-icon" class="notification-anchor-icon desktop-notification-icon" role="button"
aria-label="&urlbar.webNotsNotificationAnchor3.label;"/>
tooltiptext="&urlbar.webNotificationAnchor.tooltip;"/>
<image id="webRTC-shareDevices-notification-icon" class="notification-anchor-icon camera-icon" role="button"
aria-label="&urlbar.webRTCShareDevicesNotificationAnchor.label;"/>
tooltiptext="&urlbar.webRTCShareDevicesNotificationAnchor.tooltip;"/>
<image id="webRTC-shareMicrophone-notification-icon" class="notification-anchor-icon microphone-icon" role="button"
aria-label="&urlbar.webRTCShareMicrophoneNotificationAnchor.label;"/>
tooltiptext="&urlbar.webRTCShareMicrophoneNotificationAnchor.tooltip;"/>
<image id="webRTC-shareScreen-notification-icon" class="notification-anchor-icon screen-icon" role="button"
aria-label="&urlbar.webRTCShareScreenNotificationAnchor.label;"/>
tooltiptext="&urlbar.webRTCShareScreenNotificationAnchor.tooltip;"/>
<image id="servicesInstall-notification-icon" class="notification-anchor-icon service-icon" role="button"
aria-label="&urlbar.servicesNotificationAnchor.label;"/>
tooltiptext="&urlbar.servicesNotificationAnchor.tooltip;"/>
<image id="translate-notification-icon" class="notification-anchor-icon translation-icon" role="button"
aria-label="&urlbar.translateNotificationAnchor.label;"/>
tooltiptext="&urlbar.translateNotificationAnchor.tooltip;"/>
<image id="translated-notification-icon" class="notification-anchor-icon translation-icon in-use" role="button"
aria-label="&urlbar.translatedNotificationAnchor.label;"/>
tooltiptext="&urlbar.translatedNotificationAnchor.tooltip;"/>
<image id="eme-notification-icon" class="notification-anchor-icon drm-icon" role="button"
aria-label="&urlbar.emeNotificationAnchor.label;"/>
tooltiptext="&urlbar.emeNotificationAnchor.tooltip;"/>
</box>
<image id="tracking-protection-icon"/>
<image id="connection-icon"/>
Expand Down
45 changes: 25 additions & 20 deletions browser/locales/en-US/chrome/browser/browser.dtd
Original file line number Diff line number Diff line change
Expand Up @@ -206,26 +206,31 @@ These should match what Safari and other Apple applications use on OS X Lion. --
<!ENTITY printButton.tooltip "Print this page">

<!ENTITY urlbar.viewSiteInfo.label "View site information">
<!-- LOCALIZATION NOTE: all of the following urlbar NotificationAnchor.label strings are
used to provide accessible labels to users of assistive technology like screenreaders.
It is not possible to see them visually in the UI. -->
<!ENTITY urlbar.defaultNotificationAnchor.label "View a notification">
<!ENTITY urlbar.geolocationNotificationAnchor.label "View the location request">
<!ENTITY urlbar.addonsNotificationAnchor.label "View the add-on install message">
<!ENTITY urlbar.indexedDBNotificationAnchor.label "View the app-offline storage message">
<!ENTITY urlbar.loginFillNotificationAnchor.label "Manage your login information">
<!ENTITY urlbar.passwordNotificationAnchor.label "Check if you want to save your password">
<!ENTITY urlbar.pluginsNotificationAnchor.label "Manage plugin usage on this page">
<!ENTITY urlbar.webNotsNotificationAnchor3.label "Change whether you can receive notifications from the site">

<!ENTITY urlbar.webRTCShareDevicesNotificationAnchor.label "Manage sharing your camera and/or microphone with the site">
<!ENTITY urlbar.webRTCShareMicrophoneNotificationAnchor.label "Manage sharing your microphone with the site">
<!ENTITY urlbar.webRTCShareScreenNotificationAnchor.label "Manage sharing your windows or screen with the site">

<!ENTITY urlbar.servicesNotificationAnchor.label "View the service install message">
<!ENTITY urlbar.translateNotificationAnchor.label "Translate this page">
<!ENTITY urlbar.translatedNotificationAnchor.label "Manage page translation">
<!ENTITY urlbar.emeNotificationAnchor.label "Manage use of DRM software">

<!ENTITY urlbar.defaultNotificationAnchor.tooltip "Open message panel">
<!ENTITY urlbar.geolocationNotificationAnchor.tooltip "Open location request panel">
<!ENTITY urlbar.addonsNotificationAnchor.tooltip "Open add-on installation message panel">
<!ENTITY urlbar.indexedDBNotificationAnchor.tooltip "Open offline storage message panel">
<!ENTITY urlbar.loginFillNotificationAnchor.tooltip "Manage your login information">
<!ENTITY urlbar.passwordNotificationAnchor.tooltip "Open save password message panel">
<!ENTITY urlbar.pluginsNotificationAnchor.tooltip "Manage plug-in use">
<!ENTITY urlbar.webNotificationAnchor.tooltip "Change whether you can receive notifications from the site">

<!ENTITY urlbar.webRTCShareDevicesNotificationAnchor.tooltip "Manage sharing your camera and/or microphone with the site">
<!ENTITY urlbar.webRTCShareMicrophoneNotificationAnchor.tooltip "Manage sharing your microphone with the site">
<!ENTITY urlbar.webRTCShareScreenNotificationAnchor.tooltip "Manage sharing your windows or screen with the site">

<!ENTITY urlbar.servicesNotificationAnchor.tooltip "Open install message panel">
<!ENTITY urlbar.translateNotificationAnchor.tooltip "Translate this page">
<!ENTITY urlbar.translatedNotificationAnchor.tooltip "Manage page translation">
<!ENTITY urlbar.emeNotificationAnchor.tooltip "Manage use of DRM software">

<!ENTITY urlbar.cameraBlocked.tooltip "You have blocked your camera for this website.">
<!ENTITY urlbar.microphoneBlocked.tooltip "You have blocked your microphone for this website.">
<!ENTITY urlbar.screenBlocked.tooltip "You have blocked this website from sharing your screen.">
<!ENTITY urlbar.geolocationBlocked.tooltip "You have blocked location information for this website.">
<!ENTITY urlbar.indexedDBBlocked.tooltip "You have blocked data storage for this website.">
<!ENTITY urlbar.webNotificationsBlocked.tooltip "You have blocked notifications for this website.">

<!ENTITY urlbar.openHistoryPopup.tooltip "Show history">

Expand Down

0 comments on commit b61a85e

Please sign in to comment.