Bug 1410540 - Remove the 'viewbutton' XBL binding and pageInfo.xml;r=dao
authorBrian Grinstead <bgrinstead@mozilla.com>
Wed, 08 Nov 2017 12:26:31 -0800
changeset 444121 765f81d5cd733001a3a235495998fa199d8f9a4b
parent 444120 77d2425c4b40307d8a34fa8f6d52a8e16971e71f
child 444122 f1b40946cdbe17cfcd8846c6dc4a4475d0228f34
push id1618
push userCallek@gmail.com
push dateThu, 11 Jan 2018 17:45:48 +0000
treeherdermozilla-release@882ca853e05a [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersdao
bugs1410540
milestone58.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1410540 - Remove the 'viewbutton' XBL binding and pageInfo.xml;r=dao Instead of creating a new binding that extends the radio binding to remove the actual radio input from the DOM, with this change we use the default radio binding and hide the radio input via CSS. MozReview-Commit-ID: GMEFinhRehU
browser/base/content/pageinfo/pageInfo.css
browser/base/content/pageinfo/pageInfo.xml
browser/base/content/pageinfo/pageInfo.xul
browser/base/jar.mn
browser/themes/linux/pageInfo.css
browser/themes/osx/pageInfo.css
browser/themes/windows/pageInfo.css
--- a/browser/base/content/pageinfo/pageInfo.css
+++ b/browser/base/content/pageinfo/pageInfo.css
@@ -1,17 +1,23 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
+#viewGroup > radio > .radio-label-box {
+  -moz-box-orient: vertical;
+  -moz-box-align: center;
+}
 
-#viewGroup > radio {
-  -moz-binding: url("chrome://browser/content/pageinfo/pageInfo.xml#viewbutton");
+/* Hide the radio button for the section headers */
+#viewGroup > radio > .radio-check {
+  display: none;
 }
 
+
 richlistitem[feed] {
   -moz-binding: url("chrome://browser/content/pageinfo/feeds.xml#feed");
 }
 
 richlistitem[feed]:not([selected="true"]) .feed-subscribe {
   display: none;
 }
 
deleted file mode 100644
--- a/browser/base/content/pageinfo/pageInfo.xml
+++ /dev/null
@@ -1,20 +0,0 @@
-<?xml version="1.0"?>
-<!-- This Source Code Form is subject to the terms of the Mozilla Public
-   - License, v. 2.0. If a copy of the MPL was not distributed with this
-   - file, You can obtain one at http://mozilla.org/MPL/2.0/. -->
-
-
-<bindings id="pageInfoBindings"
-          xmlns="http://www.mozilla.org/xbl"
-          xmlns:xul="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
-          xmlns:xbl="http://www.mozilla.org/xbl">
-
-  <!-- based on preferences.xml paneButton -->
-  <binding id="viewbutton" extends="chrome://global/content/bindings/radio.xml#radio" role="xullistitem">
-    <content>
-      <xul:image class="viewButtonIcon" xbl:inherits="src"/>
-      <xul:label class="viewButtonLabel" xbl:inherits="value=label"/>
-    </content>
-  </binding>
-
-</bindings>
--- a/browser/base/content/pageinfo/pageInfo.xul
+++ b/browser/base/content/pageinfo/pageInfo.xul
@@ -76,17 +76,16 @@
       <radio id="mediaTab"    label="&mediaTab;"    accesskey="&mediaTab.accesskey;"
            oncommand="showTab('media');" hidden="true"/>
       <radio id="feedTab"     label="&feedTab;"     accesskey="&feedTab.accesskey;"
            oncommand="showTab('feed');" hidden="true"/>
       <radio id="permTab"     label="&permTab;"     accesskey="&permTab.accesskey;"
            oncommand="showTab('perm');"/>
       <radio id="securityTab" label="&securityTab;" accesskey="&securityTab.accesskey;"
            oncommand="showTab('security');"/>
-      <!-- Others added by overlay -->
     </radiogroup>
   </windowdragbox>
 
   <deck id="mainDeck" flex="1">
     <!-- General page information -->
     <vbox id="generalPanel">
       <grid id="generalGrid">
         <columns>
--- a/browser/base/jar.mn
+++ b/browser/base/jar.mn
@@ -108,17 +108,16 @@ browser.jar:
         content/browser/defaultthemes/light.icon.svg (content/defaultthemes/light.icon.svg)
         content/browser/newtab/newTab.xhtml           (content/newtab/newTab.xhtml)
 *       content/browser/newtab/newTab.js              (content/newtab/newTab.js)
         content/browser/newtab/newTab.css             (content/newtab/newTab.css)
         content/browser/newtab/alternativeDefaultSites.json   (content/newtab/alternativeDefaultSites.json)
 *       content/browser/pageinfo/pageInfo.xul         (content/pageinfo/pageInfo.xul)
         content/browser/pageinfo/pageInfo.js          (content/pageinfo/pageInfo.js)
         content/browser/pageinfo/pageInfo.css         (content/pageinfo/pageInfo.css)
-        content/browser/pageinfo/pageInfo.xml         (content/pageinfo/pageInfo.xml)
         content/browser/pageinfo/feeds.js             (content/pageinfo/feeds.js)
         content/browser/pageinfo/feeds.xml            (content/pageinfo/feeds.xml)
         content/browser/pageinfo/permissions.js       (content/pageinfo/permissions.js)
         content/browser/pageinfo/security.js          (content/pageinfo/security.js)
         content/browser/robot.ico                     (content/robot.ico)
         content/browser/static-robot.png              (content/static-robot.png)
         content/browser/safeMode.css                  (content/safeMode.css)
         content/browser/safeMode.js                   (content/safeMode.js)
--- a/browser/themes/linux/pageInfo.css
+++ b/browser/themes/linux/pageInfo.css
@@ -4,18 +4,16 @@
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 %endif
 
 @import url("chrome://global/skin/");
 
 /* View buttons */
 #viewGroup > radio {
   list-style-image: url("chrome://browser/skin/pageInfo.png");
-  -moz-box-orient: vertical;
-  -moz-box-align: center;
   -moz-appearance: none;
   min-width: 4.5em;
   margin: 0;
   padding: 3px;
   color: -moz-FieldText;
 }
 
 #viewGroup > radio[selected="true"] {
--- a/browser/themes/osx/pageInfo.css
+++ b/browser/themes/osx/pageInfo.css
@@ -2,22 +2,16 @@
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 @import "chrome://global/skin/";
 
 /* View buttons */
 @import "chrome://global/skin/viewbuttons.css";
 
-/* Extensions will provide icons because the view buttons have icons
-   on the windows and linux themes. We don't want to display them */
-.viewButtonIcon {
-  display: none;
-}
-
 deck {
   padding: 10px 10px 10px 10px;
 }
 
 /* Misc */
 tree {
   margin: .5em;
 }
--- a/browser/themes/windows/pageInfo.css
+++ b/browser/themes/windows/pageInfo.css
@@ -6,18 +6,16 @@
 
 /* View buttons */
 #viewGroup {
   padding-inline-start: 10px;
 }
 
 #viewGroup > radio {
   list-style-image: url("chrome://browser/skin/pageInfo.png");
-  -moz-box-orient: vertical;
-  -moz-box-align: center;
   -moz-appearance: none;
   padding: 5px 3px 1px 3px;
   margin: 0 1px;
   min-width: 4.5em;
 }
 
 #viewGroup > radio:hover {
   background-color: #E0E8F6;