Bug 1366405 - Stop using -moz-appearance: -moz-win-glass with the Windows 10 default theme. r?nhnt11 draft
authorDão Gottwald <dao@mozilla.com>
Sat, 23 Sep 2017 15:30:10 +0200
changeset 669477 c74bb4798add261b53e3eb0eaeb106d5bde31ce4
parent 669476 8db0c4ecd94cb62a35a25a5fe411d9f0aed7087e
child 732964 ce917bd603ab525b2c90ed29b6b12c45c7f7434e
push id81338
push userdgottwald@mozilla.com
push dateSat, 23 Sep 2017 13:30:48 +0000
reviewersnhnt11
bugs1366405
milestone58.0a1
Bug 1366405 - Stop using -moz-appearance: -moz-win-glass with the Windows 10 default theme. r?nhnt11 MozReview-Commit-ID: Dkjr831dxIV
browser/themes/windows/browser-aero.css
--- a/browser/themes/windows/browser-aero.css
+++ b/browser/themes/windows/browser-aero.css
@@ -18,31 +18,27 @@
 @media (-moz-windows-default-theme) {
   .menu-accel,
   .menu-iconic-accel {
     color: graytext;
   }
 }
 
 @media (-moz-windows-compositor) {
-  #main-window {
-    -moz-appearance: -moz-win-glass;
-  }
-
-
-  /* On win10, if we don't set this on the entire browser container including
-   * the sidebar, if the sidebar is open the accent color bleeds through in
-   * 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[sizemode=normal][tabsintitlebar] {
+          border-top: 1px solid -moz-win-accentcolor;
+        }
+
+        :root[sizemode=normal][tabsintitlebar]:-moz-window-inactive {
+          border-top-color: rgba(0,0,0,.2);
+        }
+
         :root:not(:-moz-lwtheme) {
           background-color: hsl(0, 0%, 78%);
         }
 
         @media (-moz-windows-accent-color-in-titlebar: 0) {
           :root[tabsintitlebar]:not(:-moz-lwtheme) {
             background-color: hsl(235,33%,19%);
             --titlebar-text-color: hsl(240,9%,98%);
@@ -61,16 +57,24 @@
              titlebar text change for inactive windows. */
           opacity: .6;
         }
       }
 
       @media (-moz-windows-default-theme: 0) {
         :root {
           background-color: transparent;
+          -moz-appearance: -moz-win-glass;
+        }
+
+        /* On win10, if we don't set this on the entire browser container including
+         * the sidebar, if the sidebar is open the accent color bleeds through in
+         * the titlebar */
+        #browser {
+          -moz-appearance: -moz-win-exclude-glass;
         }
       }
 
       #titlebar-buttonbox,
       .titlebar-button {
         -moz-appearance: none !important;
       }
 
@@ -225,37 +229,33 @@
           list-style-image: url(chrome://browser/skin/window-controls/close-highcontrast.svg);
         }
       }
     }
   }
 
   @media (-moz-os-version: windows-win7),
          (-moz-os-version: windows-win8) {
-    #main-window[sizemode="maximized"] #titlebar-buttonbox {
-      margin-inline-end: 3px;
+    :root {
+      background-color: transparent;
+      -moz-appearance: -moz-win-borderless-glass;
     }
 
-    #main-window {
-      background-color: transparent;
-      -moz-appearance: -moz-win-borderless-glass;
+    :root[sizemode="maximized"] #titlebar-buttonbox {
+      margin-inline-end: 3px;
     }
 
     /* These should be hidden w/ glass enabled. Windows draws its own buttons. */
     .titlebar-button {
       display: none;
     }
 
     /* The borders on the glass frame are ours, and inside #browser, and on
      * win7 we want to make sure they are "glassy", so we can't use #browser
      * as the exclude-glass container. We use #appcontent instead. */
-    #browser {
-      -moz-appearance: none;
-    }
-
     #appcontent {
       -moz-appearance: -moz-win-exclude-glass;
     }
   }
 
   @media (-moz-os-version: windows-win8) {
     /* Artificially draw window borders that are covered by lwtheme, see bug 591930.
      * Borders for win7 are below, win10 doesn't need them. */