Bug 1196266 - Use Windows 10 accent color in the title bar when in the foreground. r?johannh
MozReview-Commit-ID: EYA1rgUUbOa
--- a/browser/themes/windows/browser-aero.css
+++ b/browser/themes/windows/browser-aero.css
@@ -45,24 +45,33 @@
* the titlebar */
#browser {
-moz-appearance: -moz-win-exclude-glass;
}
@media not all and (-moz-os-version: windows-win7) {
@media not all and (-moz-os-version: windows-win8) {
@media (-moz-windows-default-theme) {
- :root:not(:-moz-lwtheme) {
%ifdef MOZ_PHOTON_THEME
+ :root:not(:-moz-window-inactive):not(:-moz-lwtheme) {
background-color: hsl(235,33%,19%);
--titlebar-text-color: hsl(240,9%,98%);
+ }
+
+ @media (-moz-windows-accent-color-applies) {
+ :root:not(:-moz-window-inactive):not(:-moz-lwtheme) {
+ background-color: -moz-win-accentcolor;
+ --titlebar-text-color: -moz-win-accentcolortext;
+ }
+ }
%else
+ :root:not(:-moz-lwtheme) {
background-color: hsl(0, 0%, 78%);
+ }
%endif
- }
:root[tabsintitlebar] .tab-label:-moz-window-inactive {
/* Calculated to match the opacity change of Windows Explorer
titlebar text change for inactive windows. */
opacity: .6;
}
}
@@ -78,17 +87,17 @@
}
.titlebar-button {
border: none;
margin: 0 !important;
padding: 10px 17px;
-moz-context-properties: stroke;
%ifdef MOZ_PHOTON_THEME
- stroke: white;
+ stroke: var(--titlebar-text-color);
%else
stroke: black;
%endif
}
:root[sizemode=maximized] .titlebar-button {
padding-top: 8px;
padding-bottom: 8px;
--- a/browser/themes/windows/browser.css
+++ b/browser/themes/windows/browser.css
@@ -10,17 +10,17 @@
%include ../shared/browser.inc
%include windowsShared.inc
%define toolbarShadowColor hsla(209,67%,12%,0.35)
%include ../shared/browser.inc.css
:root {
- --titlebar-text-color: inherit;
+ --titlebar-text-color: currentColor;
--toolbarbutton-vertical-text-padding: calc(var(--toolbarbutton-inner-padding) - 1px);
%ifdef MOZ_PHOTON_THEME
--toolbarbutton-border-radius: 2px;
%else
--space-above-tabbar: 15px;