Bug 1354097 - Style and add a customize button to the overflow panel. r=Gijs, ui-r=shorlander. draft
authorBlake Winton <bwinton@latte.ca>
Mon, 17 Jul 2017 10:18:40 -0400
changeset 614361 a958a8f6af16adce9359166a668464d377ad49bd
parent 614360 14f6123fb60132497e6e91e3df940933c2c54814
child 638855 19897fc0ce8655adae93c429e575269c041fe999
push id70000
push userbmo:bwinton@mozilla.com
push dateMon, 24 Jul 2017 14:24:15 +0000
reviewersGijs, shorlander
bugs1354097
milestone56.0a1
Bug 1354097 - Style and add a customize button to the overflow panel. r=Gijs, ui-r=shorlander. MozReview-Commit-ID: 7bNQcVgb7wf
browser/components/customizableui/content/panelUI.inc.xul
browser/locales/en-US/chrome/browser/browser.dtd
browser/themes/shared/customizableui/panelUI.inc.css
--- a/browser/components/customizableui/content/panelUI.inc.xul
+++ b/browser/components/customizableui/content/panelUI.inc.xul
@@ -405,24 +405,31 @@
        context="toolbar-context-menu"
 #endif
        hidden="true">
 #ifdef MOZ_PHOTON_THEME
   <photonpanelmultiview mainViewId="widget-overflow-mainView">
     <panelview id="widget-overflow-mainView"
                context="toolbar-context-menu">
 #endif
-      <vbox id="widget-overflow-scroller">
-        <vbox id="widget-overflow-list" class="widget-overflow-list"
-              overflowfortoolbar="nav-bar"/>
-        <toolbarseparator id="widget-overflow-fixed-separator" hidden="true"/>
-        <vbox id="widget-overflow-fixed-list" class="widget-overflow-list" hidden="true"
-              emptylabel="&customizeMode.emptyOverflowList.description;"/>
+      <vbox class="panel-subview-body">
+        <vbox id="widget-overflow-scroller">
+          <vbox id="widget-overflow-list" class="widget-overflow-list"
+                overflowfortoolbar="nav-bar"/>
+          <toolbarseparator id="widget-overflow-fixed-separator" hidden="true"/>
+          <vbox id="widget-overflow-fixed-list" class="widget-overflow-list" hidden="true"
+                emptylabel="&customizeMode.emptyOverflowList.description;"/>
+        </vbox>
       </vbox>
 #ifdef MOZ_PHOTON_THEME
+      <toolbarbutton command="cmd_CustomizeToolbars"
+                      id="overflowMenu-customize-button"
+                      class="subviewbutton panel-subview-footer"
+                      accesskey="&overflowCustomizeToolbar.accesskey;"
+                      label="&overflowCustomizeToolbar.label;"/>
     </panelview>
   </photonpanelmultiview>
 #endif
 </panel>
 
 <panel id="customization-tipPanel"
        type="arrow"
        flip="none"
--- a/browser/locales/en-US/chrome/browser/browser.dtd
+++ b/browser/locales/en-US/chrome/browser/browser.dtd
@@ -327,16 +327,18 @@ These should match what Safari and other
 <!ENTITY viewMenu.label         "View"> 
 <!ENTITY viewMenu.accesskey       "V"> 
 <!ENTITY viewToolbarsMenu.label       "Toolbars"> 
 <!ENTITY viewToolbarsMenu.accesskey     "T"> 
 <!ENTITY viewSidebarMenu.label "Sidebar">
 <!ENTITY viewSidebarMenu.accesskey "e">
 <!ENTITY viewCustomizeToolbar.label       "Customize…"> 
 <!ENTITY viewCustomizeToolbar.accesskey     "C">
+<!ENTITY overflowCustomizeToolbar.label       "Customize Toolbar…">
+<!ENTITY overflowCustomizeToolbar.accesskey   "C">
 
 <!ENTITY historyMenu.label "History">
 <!ENTITY historyMenu.accesskey "s">
 <!ENTITY historyUndoMenu.label "Recently Closed Tabs">
 <!-- LOCALIZATION NOTE (historyUndoWindowMenu): see bug 394759 -->
 <!ENTITY historyUndoWindowMenu.label "Recently Closed Windows">
 <!ENTITY historyRestoreLastSession.label "Restore Previous Session">
 
--- a/browser/themes/shared/customizableui/panelUI.inc.css
+++ b/browser/themes/shared/customizableui/panelUI.inc.css
@@ -1719,22 +1719,26 @@ toolbarpaletteitem[place=panel] > .toolb
 #widget-overflow > .panel-arrowcontainer > .panel-arrowcontent {
   padding: 0;
 }
 
 .cui-widget-panelview,
 %ifndef MOZ_PHOTON_THEME
 #widget-overflow-scroller {
 %else
-#widget-overflow-mainView {
+#widget-overflow-mainView .panel-subview-body {
 %endif
   overflow-y: auto;
   overflow-x: hidden;
 }
 
+#overflowMenu-customize-button > .toolbarbutton-text {
+  text-align: center;
+}
+
 #widget-overflow-scroller {
 %ifdef MOZ_PHOTON_THEME
   margin-top: 4px;
   margin-bottom: 4px;
 %else
   max-height: 30em;
   margin-top: 10px;
   margin-bottom: 10px;