From becf65d05a5e33e7d5d3bfa6dad9b58a1aa36298 Mon Sep 17 00:00:00 2001 From: Moonchild Date: Sat, 25 Oct 2025 17:46:17 +0200 Subject: [PATCH] Issue #2847 - Update tests and toolkit CSS to account for `windows-win11` --- layout/style/test/chrome/bug418986-2.js | 6 +----- layout/style/test/test_media_queries.html | 1 + toolkit/themes/windows/global/console/console.css | 3 ++- toolkit/themes/windows/global/toolbar.css | 5 +++-- toolkit/themes/windows/global/tree.css | 5 +++-- 5 files changed, 10 insertions(+), 10 deletions(-) diff --git a/layout/style/test/chrome/bug418986-2.js b/layout/style/test/chrome/bug418986-2.js index 4336f4abdb..ea63e0b403 100644 --- a/layout/style/test/chrome/bug418986-2.js +++ b/layout/style/test/chrome/bug418986-2.js @@ -58,18 +58,14 @@ var windows_versions = [ "windows-win7", "windows-win8", "windows-win10", + "windows-win11" ]; // Possible values for '-moz-windows-theme' var windows_themes = [ "aero", "aero-lite", - "luna-blue", - "luna-olive", - "luna-silver", - "royale", "generic", - "zune" ]; // Read the current OS. diff --git a/layout/style/test/test_media_queries.html b/layout/style/test/test_media_queries.html index a962215d34..911ee6f434 100644 --- a/layout/style/test/test_media_queries.html +++ b/layout/style/test/test_media_queries.html @@ -723,6 +723,7 @@ function run() { expression_should_be_parseable("-moz-os-version: windows-win7"); expression_should_be_parseable("-moz-os-version: windows-win8"); expression_should_be_parseable("-moz-os-version: windows-win10"); + expression_should_be_parseable("-moz-os-version: windows-win11"); expression_should_not_be_parseable("-moz-os-version: "); // OpenType SVG media features diff --git a/toolkit/themes/windows/global/console/console.css b/toolkit/themes/windows/global/console/console.css index 990ce1cf2f..d646658745 100644 --- a/toolkit/themes/windows/global/console/console.css +++ b/toolkit/themes/windows/global/console/console.css @@ -208,7 +208,8 @@ toolbar#ToolbarMode .toolbarbutton-text { } %ifdef XP_WIN -@media not all and (-moz-os-version: windows-win10) { +@media not all and (-moz-os-version: windows-win10), + not all and (-moz-os-version: windows-win11) { #ToolbarMode { -moz-appearance: -moz-win-browsertabbar-toolbox; } diff --git a/toolkit/themes/windows/global/toolbar.css b/toolkit/themes/windows/global/toolbar.css index 0a6eb943a0..486cdf0be5 100644 --- a/toolkit/themes/windows/global/toolbar.css +++ b/toolkit/themes/windows/global/toolbar.css @@ -17,9 +17,10 @@ toolbox { -moz-border-top-colors: ThreeDShadow ThreeDHighlight; } -@media (-moz-os-version: windows-win10) and (-moz-windows-theme: aero) { +@media (-moz-os-version: windows-win10) and (-moz-windows-theme: aero), + (-moz-os-version: windows-win11) and (-moz-windows-theme: aero) { toolbox { - /* Windows 10's "aero" msstyle sourced toolbox background is pure white + /* Windows 10/11's "aero" msstyle sourced toolbox background is pure white so don't use the widget toolbox styling and fallback to -moz-Dialog's color which by default should be a non-blinding rgb(240, 240, 240) */ -moz-appearance: none; diff --git a/toolkit/themes/windows/global/tree.css b/toolkit/themes/windows/global/tree.css index ee176296b2..e2e0f8c40a 100644 --- a/toolkit/themes/windows/global/tree.css +++ b/toolkit/themes/windows/global/tree.css @@ -198,9 +198,10 @@ treechildren::-moz-tree-cell-text(progressmeter) { /* ::::: tree columns ::::: */ -@media (-moz-os-version: windows-win10) and (-moz-windows-theme: aero) { +@media (-moz-os-version: windows-win10) and (-moz-windows-theme: aero), + (-moz-os-version: windows-win11) and (-moz-windows-theme: aero) { treecols { - /* Windows 10's "aero" msstyle does not provide a complete style for + /* Windows 10/11's "aero" msstyle does not provide a complete style for the treecols header so we need to provide a bottom border */ border-bottom: 1px solid ThreeDLightShadow; }