Bug 1058039 - Make sure that .addon-control subitem elements from Plugin Add-on Manager are not hidden (otherwise the state menu selectbox will not inherit a good width). r=Unfocused
authorAlex Bardas <abardas@mozilla.com>
Wed, 27 Aug 2014 19:04:00 +0200
changeset 223752 141dc6c20917c7fcd027d6c44df09a1058880525
parent 223751 dc6bb1c3bfbc2c5ef2338604244264ad0ff80ab0
child 223753 47c9418fbc28608e6b9b2c0b1f1664b183bd5b30
child 223810 b48dd68342d7f35cd14fa6e9dbc92ce554c0bad6
push id3979
push userraliiev@mozilla.com
push dateMon, 13 Oct 2014 16:35:44 +0000
treeherdermozilla-beta@30f2cc610691 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersUnfocused
bugs1058039
milestone34.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 1058039 - Make sure that .addon-control subitem elements from Plugin Add-on Manager are not hidden (otherwise the state menu selectbox will not inherit a good width). r=Unfocused
toolkit/mozapps/extensions/test/browser/browser_plugin_enabled_state_locked.js
toolkit/themes/linux/mozapps/extensions/extensions.css
toolkit/themes/osx/mozapps/extensions/extensions.css
toolkit/themes/windows/mozapps/extensions/extensions.css
--- a/toolkit/mozapps/extensions/test/browser/browser_plugin_enabled_state_locked.js
+++ b/toolkit/mozapps/extensions/test/browser/browser_plugin_enabled_state_locked.js
@@ -52,20 +52,24 @@ function getTestPlugin(aPlugins) {
 
   return pluginElement;
 }
 
 function checkStateMenu(locked) {
   Assert.equal(Services.prefs.prefIsLocked(getTestPluginPref()), locked,
     "Preference lock state should be correct.");
   let menuList = gManagerWindow.document.getAnonymousElementByAttribute(gPluginElement, "anonid", "state-menulist");
+  //  State menu should always have a selected item which must be visible
+  let selectedMenuItem = menuList.querySelector(".addon-control[selected=\"true\"]");
 
   is_element_visible(menuList, "State menu should be visible.");
   Assert.equal(menuList.disabled, locked,
     "State menu should" + (locked === true ? "" : " not") + " be disabled.");
+
+  is_element_visible(selectedMenuItem, "State menu's selected item should be visible.");
 }
 
 function checkStateMenuDetail(locked) {
   Assert.equal(Services.prefs.prefIsLocked(getTestPluginPref()), locked,
     "Preference should be " + (locked === true ? "" : "un") + "locked.");
 
   // open details menu
   let details = gManagerWindow.document.getAnonymousElementByAttribute(gPluginElement, "anonid", "details-btn");
--- a/toolkit/themes/linux/mozapps/extensions/extensions.css
+++ b/toolkit/themes/linux/mozapps/extensions/extensions.css
@@ -875,22 +875,22 @@ setting[type="radio"] > radiogroup {
 
 #update-selected {
   margin: 12px;
 }
 
 
 /*** buttons ***/
 
-.addon-control[disabled="true"] {
+.addon-control[disabled="true"]:not(.no-auto-hide) {
   display: none;
 }
 
-.addon-control.no-auto-hide {
-  display: block;
+.no-auto-hide .addon-control {
+  display: block !important;
 }
 
 .addon-control.enable {
   list-style-image: url("moz-icon://stock/gtk-yes?size=button");
 }
 
 .addon-control.disable {
   list-style-image: url("moz-icon://stock/gtk-no?size=button");
--- a/toolkit/themes/osx/mozapps/extensions/extensions.css
+++ b/toolkit/themes/osx/mozapps/extensions/extensions.css
@@ -1099,22 +1099,26 @@ setting[type="radio"] > radiogroup {
 
 #update-selected {
   margin: 12px;
 }
 
 
 /*** buttons ***/
 
-.addon-control[disabled="true"] {
+.addon-control[disabled="true"]:not(.no-auto-hide) {
   display: none;
 }
 
-.addon-control.no-auto-hide {
-  display: block;
+.no-auto-hide .addon-control {
+  display: block !important;
+}
+
+.no-auto-hide > .menulist-dropmarker {
+  -moz-padding-start: 0px !important;
 }
 
 button.button-link {
   -moz-appearance: none;
   background: transparent;
   border: none;
   box-shadow: none;
   text-decoration: underline;
--- a/toolkit/themes/windows/mozapps/extensions/extensions.css
+++ b/toolkit/themes/windows/mozapps/extensions/extensions.css
@@ -1115,22 +1115,22 @@ menulist { /* Fixes some styling inconsi
 
 #update-selected {
   margin: 12px;
 }
 
 
 /*** buttons ***/
 
-.addon-control[disabled="true"] {
+.addon-control[disabled="true"]:not(.no-auto-hide) {
   display: none;
 }
 
-.addon-control.no-auto-hide {
-  display: block;
+.no-auto-hide .addon-control {
+  display: block !important;
 }
 
 button.button-link {
   -moz-appearance: none;
   background: transparent;
   border: none;
   box-shadow: none;
   text-decoration: underline;