Bug 1368672 - Don't set a color on toolbar buttons by default (color should be inherited) and explicitly inherit color in hover/open states for custom-styled toolbar buttons. r=johannh
authorDão Gottwald <dao@mozilla.com>
Tue, 06 Jun 2017 12:57:58 +0200
changeset 410629 829a5b7de7cf408137e4ec270f1ccb9a153de411
parent 410628 e5bd43668caaa8dbb97b5709b3af725299e93faf
child 410630 1dd8e8368519d34307caf0a2916ce4d3fc60329c
push id7391
push usermtabara@mozilla.com
push dateMon, 12 Jun 2017 13:08:53 +0000
treeherdermozilla-beta@2191d7f87e2e [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersjohannh
bugs1368672
milestone55.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 1368672 - Don't set a color on toolbar buttons by default (color should be inherited) and explicitly inherit color in hover/open states for custom-styled toolbar buttons. r=johannh MozReview-Commit-ID: J2QF8FBi0Ll
browser/themes/shared/toolbarbuttons.inc.css
toolkit/themes/linux/global/toolbarbutton.css
toolkit/themes/osx/global/toolbarbutton.css
toolkit/themes/windows/global/toolbarbutton.css
--- a/browser/themes/shared/toolbarbuttons.inc.css
+++ b/browser/themes/shared/toolbarbuttons.inc.css
@@ -289,32 +289,34 @@ toolbarbutton.bookmark-item:not(.subview
 @conditionalForwardWithUrlbar@ > #forward-button:not([open]):not(:active):not([disabled]):hover > .toolbarbutton-icon,
 %endif
 #nav-bar .toolbarbutton-1:not([buttonover]):not([open]):not(:active):hover > .toolbarbutton-menubutton-dropmarker:not([disabled]) > .dropmarker-icon {
   background: var(--toolbarbutton-hover-background);
 %ifndef MOZ_PHOTON_THEME
   border-color: var(--toolbarbutton-hover-bordercolor);
   box-shadow: var(--toolbarbutton-hover-boxshadow);
 %endif
+  color: inherit;
 }
 
 .findbar-button:not([disabled=true]):-moz-any([checked="true"],:hover:active) > .toolbarbutton-text,
 toolbarbutton.bookmark-item:not(.subviewbutton):hover:active:not([disabled="true"]),
 toolbarbutton.bookmark-item[open="true"],
 #nav-bar .toolbarbutton-1 > .toolbarbutton-menubutton-button:not([disabled=true]):-moz-any(:hover:active, [open]) > .toolbarbutton-icon,
 #nav-bar .toolbarbutton-1[open] > .toolbarbutton-menubutton-dropmarker:not([disabled=true]) > .dropmarker-icon,
 #nav-bar .toolbarbutton-1:not([disabled=true]):-moz-any([open],[checked],:hover:active) > .toolbarbutton-icon,
 #nav-bar .toolbarbutton-1:not([disabled=true]):-moz-any([open],[checked],:hover:active) > .toolbarbutton-text,
 #nav-bar .toolbarbutton-1:not([disabled=true]):-moz-any([open],[checked],:hover:active) > .toolbarbutton-badge-stack {
   background: var(--toolbarbutton-active-background);
 %ifndef MOZ_PHOTON_THEME
   border-color: var(--toolbarbutton-active-bordercolor);
   box-shadow: var(--toolbarbutton-active-boxshadow);
 %endif
   transition-duration: 10ms;
+  color: inherit;
 }
 
 #nav-bar .toolbarbutton-1[checked]:not(:active):hover > .toolbarbutton-icon {
   background-color: var(--toolbarbutton-checkedhover-backgroundcolor);
   transition: background-color .4s;
 }
 
 %ifndef MOZ_PHOTON_THEME
--- a/toolkit/themes/linux/global/toolbarbutton.css
+++ b/toolkit/themes/linux/global/toolbarbutton.css
@@ -11,17 +11,16 @@
 /* ::::: toolbarbutton ::::: */
 
 toolbarbutton {
   -moz-appearance: toolbarbutton;
   -moz-box-align: center;
   -moz-box-pack: center;
   margin: 0;
   padding: 3px;
-  color: -moz-DialogText;
 }
 
 toolbarbutton:-moz-lwtheme {
   text-shadow: none;
 }
 
 .toolbarbutton-icon[label]:not([label=""]),
 .toolbarbutton-icon[type="menu"] {
@@ -58,17 +57,16 @@ toolbarbutton[disabled="true"][open="tru
   color: GrayText;
 }
 
 toolbarbutton[checked="true"]:not(:hover) {
   color: ButtonText;
 }
 
 toolbarbutton:-moz-lwtheme:not(:hover):not([checked="true"]):not([open="true"]):not([disabled="true"]) {
-  color: inherit;
   text-shadow: inherit;
 }
 
 /* ::::: toolbarbutton menu ::::: */
 
 .toolbarbutton-menu-dropmarker {
   -moz-appearance: toolbarbutton-dropdown !important;
   list-style-image: none;
--- a/toolkit/themes/osx/global/toolbarbutton.css
+++ b/toolkit/themes/osx/global/toolbarbutton.css
@@ -24,17 +24,17 @@ toolbarbutton:not([disabled="true"]):act
   text-align: center;
   vertical-align: middle;
 }
 
 toolbarbutton[disabled="true"],
 toolbarbutton[disabled="true"]:hover,
 toolbarbutton[disabled="true"]:hover:active,
 toolbarbutton[disabled="true"][open="true"] {
-  color: -moz-mac-disabledtoolbartext !important;
+  color: -moz-mac-disabledtoolbartext;
 }
 
 /* ::::: toolbarbutton menu ::::: */
 
 .toolbarbutton-menu-dropmarker {
   -moz-appearance: none !important;
   border: none !important;
   background-color: transparent !important;
--- a/toolkit/themes/windows/global/toolbarbutton.css
+++ b/toolkit/themes/windows/global/toolbarbutton.css
@@ -11,17 +11,16 @@
 /* ::::: toolbarbutton ::::: */
 
 toolbarbutton {
   -moz-appearance: toolbarbutton;
   -moz-box-align: center;
   -moz-box-pack: center;
   margin: 0;
   padding: 3px;
-  color: -moz-DialogText;
 }
 
 .toolbarbutton-icon[label]:not([label=""]),
 .toolbarbutton-icon[type="menu"] {
   margin-inline-end: 5px;
 }
 
 .toolbarbutton-text {
@@ -71,28 +70,26 @@ toolbarbutton[checked="true"]:not([disab
 }
 
 @media (-moz-windows-default-theme) {
   toolbarbutton:-moz-lwtheme {
     text-shadow: none;
   }
 
   toolbarbutton:-moz-lwtheme:not([disabled="true"]) {
-    color: inherit;
     text-shadow: inherit;
   }
 }
 
 @media (-moz-windows-default-theme: 0) {
   toolbarbutton:-moz-lwtheme {
     -moz-appearance: none;
   }
 
   toolbarbutton:-moz-lwtheme:not([disabled="true"]) {
-    color: inherit;
     text-shadow: inherit;
   }
 }
 
 /* ::::: toolbarbutton menu ::::: */
 
 .toolbarbutton-menu-dropmarker {
   -moz-appearance: none !important;