Bug 1712569 - Restore tooltip to reader view button. r=adw
authorHarry Twyford <htwyford@mozilla.com>
Sun, 30 May 2021 16:04:16 +0000
changeset 581457 1514fcbf80a014f6e3b96d8815f53a9b4ebd3303
parent 581456 8ff8917c0ae0c761728a6e6ea29f55eed9c6d394
child 581458 71e296a327affe60305f9375e19b11aa1bbd3d49
push id144032
push userhtwyford@mozilla.com
push dateSun, 30 May 2021 16:06:42 +0000
treeherderautoland@1514fcbf80a0 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersadw
bugs1712569
milestone90.0a1
first release with
nightly linux32
1514fcbf80a0 / 90.0a1 / 20210530214555 / files
nightly linux64
1514fcbf80a0 / 90.0a1 / 20210530214555 / files
nightly mac
1514fcbf80a0 / 90.0a1 / 20210530214555 / files
nightly win32
1514fcbf80a0 / 90.0a1 / 20210530214555 / files
nightly win64
1514fcbf80a0 / 90.0a1 / 20210530214555 / files
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
releases
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1712569 - Restore tooltip to reader view button. r=adw Differential Revision: https://phabricator.services.mozilla.com/D116273
browser/base/content/browser.js
browser/base/content/browser.xhtml
--- a/browser/base/content/browser.js
+++ b/browser/base/content/browser.js
@@ -6674,17 +6674,17 @@ const nodeToTooltipMap = {
   "appMenu-copy-button": "copy-button.tooltip",
   "appMenu-paste-button": "paste-button.tooltip",
   "appMenu-zoomEnlarge-button": "zoomEnlarge-button.tooltip",
   "appMenu-zoomEnlarge-button2": "zoomEnlarge-button.tooltip",
   "appMenu-zoomReset-button": "zoomReset-button.tooltip",
   "appMenu-zoomReset-button2": "zoomReset-button.tooltip",
   "appMenu-zoomReduce-button": "zoomReduce-button.tooltip",
   "appMenu-zoomReduce-button2": "zoomReduce-button.tooltip",
-  "reader-mode-button": "reader-mode-button.tooltip",
+  "reader-mode-button-icon": "reader-mode-button.tooltip",
   "print-button": "printButton.tooltip",
 };
 const nodeToShortcutMap = {
   "bookmarks-menu-button": "manBookmarkKb",
   "context-reload": "key_reload",
   "context-stop": "key_stop",
   "downloads-button": "key_openDownloads",
   "fullscreen-button": "key_fullScreen",
@@ -6700,17 +6700,17 @@ const nodeToShortcutMap = {
   "appMenu-copy-button": "key_copy",
   "appMenu-paste-button": "key_paste",
   "appMenu-zoomEnlarge-button": "key_fullZoomEnlarge",
   "appMenu-zoomEnlarge-button2": "key_fullZoomEnlarge",
   "appMenu-zoomReset-button": "key_fullZoomReset",
   "appMenu-zoomReset-button2": "key_fullZoomReset",
   "appMenu-zoomReduce-button": "key_fullZoomReduce",
   "appMenu-zoomReduce-button2": "key_fullZoomReduce",
-  "reader-mode-button": "key_toggleReaderMode",
+  "reader-mode-button-icon": "key_toggleReaderMode",
   "print-button": "printKb",
 };
 
 const gDynamicTooltipCache = new Map();
 function GetDynamicShortcutTooltipText(nodeId) {
   if (!gDynamicTooltipCache.has(nodeId) && nodeId in nodeToTooltipMap) {
     let strId = nodeToTooltipMap[nodeId];
     let args = [];
--- a/browser/base/content/browser.xhtml
+++ b/browser/base/content/browser.xhtml
@@ -2000,17 +2000,18 @@
                   <image id="userContext-indicator"/>
                 </hbox>
                 <hbox id="reader-mode-button"
                       class="urlbar-page-action urlbar-icon-wrapper"
                       role="button"
                       hidden="true"
                       tooltip="dynamic-shortcut-tooltip"
                       onclick="AboutReaderParent.buttonClick(event);">
-                  <image class="urlbar-icon"/>
+                  <image id="reader-mode-button-icon"
+                         class="urlbar-icon"/>
                 </hbox>
                 <toolbarbutton id="urlbar-zoom-button"
                        onclick="FullZoom.reset(); FullZoom.resetScalingZoom();"
                        tooltip="dynamic-shortcut-tooltip"
                        hidden="true"/>
                 <hbox id="pageActionButton"
                       class="urlbar-page-action urlbar-icon-wrapper"
                       role="button"