diff options
author | Matt A. Tobin <email@mattatobin.com> | 2018-02-23 08:01:32 -0500 |
---|---|---|
committer | Matt A. Tobin <email@mattatobin.com> | 2018-02-23 08:01:32 -0500 |
commit | 38e595cb2d37cb30b094e9e79c9a73ef16baab1a (patch) | |
tree | 6a479babf0ae47dd4a57d50a2747775aed5dc52e | |
parent | a4adb6827f02bd4a34ab9c650127853d2e46bccb (diff) | |
parent | 7eb2c156ba826a0ebf05db56a9fccf46094478ea (diff) | |
download | uxp-38e595cb2d37cb30b094e9e79c9a73ef16baab1a.tar.gz |
Merge branch 'master' into eme
202 files changed, 1671 insertions, 1075 deletions
diff --git a/browser/base/content/aboutDialog.js b/browser/base/content/aboutDialog.js index b024d2d52d..f9571621f2 100644 --- a/browser/base/content/aboutDialog.js +++ b/browser/base/content/aboutDialog.js @@ -40,16 +40,23 @@ function init(aEvent) // Pref is unset } - // Include the build ID and display warning if this is an "a#" (nightly or aurora) build + // Include the build ID let versionField = document.getElementById("version"); let version = Services.appinfo.version; + let buildID = Services.appinfo.appBuildID; + let year = buildID.slice(0, 4); + let month = buildID.slice(4, 6); + let day = buildID.slice(6, 8); + let hour = buildID.slice(8, 10); + let minute = buildID.slice(10, 12); + if (Services.prefs.getBoolPref("general.useragent.appVersionIsBuildID")) { + versionField.textContent = `${year}.${month}.${day}`; + } else { + versionField.textContent = `v` + version + ` (${year}-${month}-${day})`; + } + + // Display warning if this is an "a#" (nightly or aurora) build if (/a\d+$/.test(version)) { - let buildID = Services.appinfo.appBuildID; - let year = buildID.slice(0, 4); - let month = buildID.slice(4, 6); - let day = buildID.slice(6, 8); - versionField.textContent += ` (${year}-${month}-${day})`; - document.getElementById("experimental").hidden = false; document.getElementById("communityDesc").hidden = true; } diff --git a/browser/base/content/aboutDialog.xul b/browser/base/content/aboutDialog.xul index ef2804f319..f64e79681d 100644 --- a/browser/base/content/aboutDialog.xul +++ b/browser/base/content/aboutDialog.xul @@ -45,7 +45,7 @@ <vbox id="leftBox" flex="1"/> <vbox id="rightBox" flex="1"> <hbox align="baseline"> -#expand <label id="version">__MOZ_APP_VERSION_DISPLAY__</label> +#expand <label id="version"></label> #ifndef NIGHTLY_BUILD <label id="releasenotes" class="text-link">&releaseNotes.link;</label> #endif @@ -120,19 +120,13 @@ <vbox id="experimental" hidden="true"> <description class="text-blurb" id="warningDesc"> &warningDesc.version; -#ifdef MOZ_TELEMETRY_ON_BY_DEFAULT - &warningDesc.telemetryDesc; -#endif - </description> - <description class="text-blurb" id="communityExperimentalDesc"> - &community.exp.start;<label class="text-link" href="http://www.mozilla.org/">&community.exp.mozillaLink;</label>&community.exp.middle;<label class="text-link" useoriginprincipal="true" href="about:credits">&community.exp.creditsLink;</label>&community.exp.end; </description> </vbox> <description class="text-blurb" id="communityDesc"> - &community.start2;<label class="text-link" href="http://www.mozilla.org/">&community.mozillaLink;</label>&community.middle2;<label class="text-link" useoriginprincipal="true" href="about:credits">&community.creditsLink;</label>&community.end3; + Basilisk is community software released by <label class="text-link" href="http://www.palemoon.org/">the Pale Moon team</label> and Mozilla developers. Learn <label class="text-link" useoriginprincipal="true" href="about:credits">who contributed</label> to this software. </description> <description class="text-blurb" id="contributeDesc"> - &helpus.start;<label class="text-link" href="https://sendto.mozilla.org/page/contribute/Give-Now?source=mozillaorg_default_footer&ref=firefox_about&utm_campaign=firefox_about&tm_source=firefox&tm_medium=referral&utm_content=20140929_FireFoxAbout">&helpus.donateLink;</label>&helpus.middle;<label class="text-link" href="http://www.mozilla.org/contribute/">&helpus.getInvolvedLink;</label>&helpus.end; + Want to help? Please consider <label class="text-link" href="https://www.palemoon.org/donations.shtml">donating</label> or get involved with our <label class="text-link" href="https://github.com/MoonchildProductions/moebius">development</label> of the Unified XUL Platform. </description> </vbox> </vbox> @@ -141,7 +135,7 @@ <hbox pack="center"> <label class="text-link bottom-link" useoriginprincipal="true" href="about:license">&bottomLinks.license;</label> <label class="text-link bottom-link" useoriginprincipal="true" href="about:rights">&bottomLinks.rights;</label> - <label class="text-link bottom-link" href="https://www.mozilla.org/privacy/">&bottomLinks.privacy;</label> + <label class="text-link bottom-link" href="https://www.palemoon.org/privacy.shtml">&bottomLinks.privacy;</label> </hbox> <description id="trademark">&trademarkInfo.part1;</description> </vbox> diff --git a/browser/base/content/browser-places.js b/browser/base/content/browser-places.js index 14e90cde2c..a447880be3 100644 --- a/browser/base/content/browser-places.js +++ b/browser/base/content/browser-places.js @@ -1555,6 +1555,10 @@ var BookmarkingUI = { // so kill current view and let popupshowing generate a new one. if (this.button._placesView) this.button._placesView.uninit(); + // ...and do the same for the menu bar. + let menubar = document.getElementById("bookmarksMenu"); + if (menubar && menubar._placesView) + menubar._placesView.uninit(); // We have to do the same thing for the "special" views underneath the // the bookmarks menu. diff --git a/browser/branding/official/pref/firefox-branding.js b/browser/branding/official/pref/firefox-branding.js index eb2bf489b5..190b84e78d 100644 --- a/browser/branding/official/pref/firefox-branding.js +++ b/browser/branding/official/pref/firefox-branding.js @@ -37,6 +37,10 @@ pref("app.update.url.manual", "https://@BRANDING_SITEURL@/"); // supplied in the "An update is available" page of the update wizard. pref("app.update.url.details", "https://@BRANDING_SITEURL@/@BRANDING_RELNOTESPATH@"); +// Provide UA Gecko and Firefox slices for web compatibility +pref("general.useragent.compatMode.firefox",true); +pref("general.useragent.compatMode.gecko",true); + // Switch Application Updates off for now pref("app.update.enabled", false); diff --git a/browser/components/nsBrowserGlue.js b/browser/components/nsBrowserGlue.js index d69a11f6b0..f97c173a00 100644 --- a/browser/components/nsBrowserGlue.js +++ b/browser/components/nsBrowserGlue.js @@ -64,6 +64,7 @@ XPCOMUtils.defineLazyServiceGetter(this, "AlertsService", "@mozilla.org/alerts-s ["Task", "resource://gre/modules/Task.jsm"], ["UITour", "resource:///modules/UITour.jsm"], ["URLBarZoom", "resource:///modules/URLBarZoom.jsm"], + ["UserAgentOverrides", "resource://gre/modules/UserAgentOverrides.jsm"], ["WebChannel", "resource://gre/modules/WebChannel.jsm"], ["WindowsRegistry", "resource://gre/modules/WindowsRegistry.jsm"], ["webrtcUI", "resource:///modules/webrtcUI.jsm"], @@ -662,6 +663,8 @@ BrowserGlue.prototype = { } } catch (ex) { /* missing any of the prefs is not critical */ } + UserAgentOverrides.init(); + PageThumbs.init(); webrtcUI.init(); AboutHome.init(); @@ -1042,6 +1045,7 @@ BrowserGlue.prototype = { BrowserUsageTelemetry.uninit(); SelfSupportBackend.uninit(); + UserAgentOverrides.uninit(); PageThumbs.uninit(); NewTabMessages.uninit(); AboutNewTab.uninit(); diff --git a/browser/components/webextensions/extension-win-panel.css b/browser/components/webextensions/extension-win-panel.css index ddafe3ea59..9da6da14cc 100644 --- a/browser/components/webextensions/extension-win-panel.css +++ b/browser/components/webextensions/extension-win-panel.css @@ -1,6 +1,4 @@ -@media (-moz-os-version: windows-xp), - (-moz-os-version: windows-vista), - (-moz-os-version: windows-win7) { +@media (-moz-os-version: windows-win7) { body { border-radius: 4px; } diff --git a/browser/config/version.txt b/browser/config/version.txt index b406fbef67..d90a8c2200 100644 --- a/browser/config/version.txt +++ b/browser/config/version.txt @@ -1 +1 @@ -55.0.0 +52.9.0 diff --git a/browser/config/version_display.txt b/browser/config/version_display.txt index b406fbef67..d90a8c2200 100644 --- a/browser/config/version_display.txt +++ b/browser/config/version_display.txt @@ -1 +1 @@ -55.0.0 +52.9.0 diff --git a/browser/confvars.sh b/browser/confvars.sh index 65cf154e9e..0cccede384 100755 --- a/browser/confvars.sh +++ b/browser/confvars.sh @@ -18,7 +18,7 @@ if test "$OS_ARCH" = "WINNT"; then MOZ_MAINTENANCE_SERVICE= fi -# For Basilisk we want to use 55.0.YYYY.MM.DD as MOZ_APP_VERSION in release +# For Basilisk we want to use 52.9.YYYY.MM.DD as MOZ_APP_VERSION in release # builds so add-on developers have something to target while maintaining # Firefox compatiblity. # To enable add "export BASILISK_VERSION=1" to the .mozconfig file. @@ -26,7 +26,7 @@ fi # don't export the variable if you are in development or don't care. # When not exported we fall back the value in the version*.txt file. if test -n "$BASILISK_VERSION" ; then - MOZ_APP_VERSION=55.0.`date --utc '+%Y.%m.%d'` + MOZ_APP_VERSION=52.9.`date --utc '+%Y.%m.%d'` MOZ_APP_VERSION_DISPLAY=`date --utc '+%Y.%m.%d'` else MOZ_APP_VERSION=`cat ${_topsrcdir}/$MOZ_BUILD_APP/config/version.txt` diff --git a/browser/installer/allowed-dupes.mn b/browser/installer/allowed-dupes.mn index 3668425984..7baa6ebedc 100644 --- a/browser/installer/allowed-dupes.mn +++ b/browser/installer/allowed-dupes.mn @@ -171,7 +171,7 @@ chrome/toolkit/skin/classic/global/dialog.css chrome/toolkit/skin/classic/global/dropmarker.css chrome/toolkit/skin/classic/global/global.css chrome/toolkit/skin/classic/global/groupbox.css -chrome/toolkit/skin/classic/global/icons/close-XPVista7.png +chrome/toolkit/skin/classic/global/icons/close-win7.png chrome/toolkit/skin/classic/global/icons/tabprompts-bgtexture.png chrome/toolkit/skin/classic/global/listbox.css chrome/toolkit/skin/classic/global/media/clicktoplay-bgtexture.png @@ -196,7 +196,6 @@ chrome/toolkit/skin/classic/global/toolbarbutton.css chrome/toolkit/skin/classic/global/tree.css chrome/toolkit/skin/classic/global/wizard.css chrome/toolkit/skin/classic/mozapps/downloads/buttons.png -chrome/toolkit/skin/classic/mozapps/downloads/downloadButtons-XP.png chrome/toolkit/skin/classic/mozapps/downloads/downloadButtons.png chrome/toolkit/skin/classic/mozapps/extensions/category-dictionaries.png chrome/toolkit/skin/classic/mozapps/extensions/category-experiments.png @@ -209,7 +208,6 @@ chrome/toolkit/skin/classic/mozapps/extensions/localeGeneric.png chrome/toolkit/skin/classic/mozapps/extensions/category-extensions.png chrome/toolkit/skin/classic/mozapps/extensions/extensionGeneric.png chrome/toolkit/skin/classic/mozapps/update/buttons.png -chrome/toolkit/skin/classic/mozapps/update/downloadButtons-XP.png chrome/toolkit/skin/classic/mozapps/update/downloadButtons.png chrome/toolkit/skin/classic/mozapps/xpinstall/xpinstallItemGeneric.png diff --git a/browser/themes/shared/incontentprefs/preferences.inc.css b/browser/themes/shared/incontentprefs/preferences.inc.css index 577baa6ed5..0e62660de9 100644 --- a/browser/themes/shared/incontentprefs/preferences.inc.css +++ b/browser/themes/shared/incontentprefs/preferences.inc.css @@ -173,6 +173,11 @@ treecol { margin-inline-start: 0; } +#browserHomePage:-moz-locale-dir(rtl) input { + unicode-bidi: plaintext; + direction: rtl; +} + /* Content pane */ #playDRMContentLink { /* Line up with the buttons in the other grid bits: */ diff --git a/browser/themes/windows/Info-XP.png b/browser/themes/windows/Info-XP.png Binary files differdeleted file mode 100644 index c20f66ce62..0000000000 --- a/browser/themes/windows/Info-XP.png +++ /dev/null diff --git a/browser/themes/windows/Privacy-16-XP.png b/browser/themes/windows/Privacy-16-XP.png Binary files differdeleted file mode 100644 index 335febbb3c..0000000000 --- a/browser/themes/windows/Privacy-16-XP.png +++ /dev/null diff --git a/browser/themes/windows/Toolbar-XP.png b/browser/themes/windows/Toolbar-XP.png Binary files differdeleted file mode 100644 index dff60911f9..0000000000 --- a/browser/themes/windows/Toolbar-XP.png +++ /dev/null diff --git a/browser/themes/windows/Toolbar-lunaSilver.png b/browser/themes/windows/Toolbar-lunaSilver.png Binary files differdeleted file mode 100644 index 30c425c26b..0000000000 --- a/browser/themes/windows/Toolbar-lunaSilver.png +++ /dev/null diff --git a/browser/themes/windows/Toolbar-aero.png b/browser/themes/windows/Toolbar-win7.png Binary files differindex b191ce2aab..b191ce2aab 100644 --- a/browser/themes/windows/Toolbar-aero.png +++ b/browser/themes/windows/Toolbar-win7.png diff --git a/browser/themes/windows/Toolbar-aero@2x.png b/browser/themes/windows/Toolbar-win7@2x.png Binary files differindex 033d87dff5..033d87dff5 100644 --- a/browser/themes/windows/Toolbar-aero@2x.png +++ b/browser/themes/windows/Toolbar-win7@2x.png diff --git a/browser/themes/windows/actionicon-tab-XPVista7.png b/browser/themes/windows/actionicon-tab-win7.png Binary files differindex 8437c7655a..8437c7655a 100644 --- a/browser/themes/windows/actionicon-tab-XPVista7.png +++ b/browser/themes/windows/actionicon-tab-win7.png diff --git a/browser/themes/windows/browser-aero.css b/browser/themes/windows/browser-aero.css index 28599af7a0..dbac6bb7a3 100644 --- a/browser/themes/windows/browser-aero.css +++ b/browser/themes/windows/browser-aero.css @@ -445,7 +445,7 @@ } /* The borders on the glass frame are ours, and inside #browser, and on - * vista and win7 we want to make sure they are "glassy", so we can't use + * 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; @@ -458,7 +458,7 @@ @media (-moz-os-version: windows-win8) { /* Artificially draw window borders that are covered by lwtheme, see bug 591930. - * Borders for vista/win7 are below, win10 doesn't need them. */ + * Borders for win7 are below, win10 doesn't need them. */ #main-window[sizemode="normal"] > #tab-view-deck > #browser-panel:-moz-lwtheme { border-top: 1px solid @toolbarShadowColor@; } @@ -473,11 +473,9 @@ * On aero, the menubar fog disappears for inactive windows, and renders gray * illegible. */ - @media not all and (-moz-os-version: windows-vista) { - @media not all and (-moz-os-version: windows-win7) { - #toolbar-menubar:not(:-moz-lwtheme):-moz-window-inactive { - color: ThreeDShadow; - } + @media not all and (-moz-os-version: windows-win7) { + #toolbar-menubar:not(:-moz-lwtheme):-moz-window-inactive { + color: ThreeDShadow; } } } @@ -487,9 +485,8 @@ color: white; } - /* Show borders on vista through win8, but not on win10 and later: */ - @media (-moz-os-version: windows-vista), - (-moz-os-version: windows-win7), + /* Show borders on win7 and win8, but not on win10 and later: */ + @media (-moz-os-version: windows-win7), (-moz-os-version: windows-win8) { /* Vertical toolbar border */ #main-window:not([customizing])[sizemode=normal] #navigator-toolbox > toolbar:not(#toolbar-menubar):not(#TabsToolbar):not(:-moz-lwtheme), diff --git a/browser/themes/windows/browser.css b/browser/themes/windows/browser.css index 15e776da16..a0cdabfb28 100644 --- a/browser/themes/windows/browser.css +++ b/browser/themes/windows/browser.css @@ -131,8 +131,7 @@ toolbar:-moz-lwtheme { } @media (-moz-windows-default-theme) { - @media (-moz-os-version: windows-vista), - (-moz-os-version: windows-win7) { + @media (-moz-os-version: windows-win7) { #navigator-toolbox::after { border-bottom-color: #aabccf; } @@ -160,9 +159,7 @@ toolbar:-moz-lwtheme { background-image: linear-gradient(@toolbarHighlight@, @toolbarHighlight@); } -@media (-moz-os-version: windows-xp), - (-moz-os-version: windows-vista), - (-moz-os-version: windows-win7) { +@media (-moz-os-version: windows-win7) { #nav-bar { background-image: linear-gradient(@toolbarHighlight@, transparent) !important; } @@ -318,64 +315,6 @@ toolbar:-moz-lwtheme { } } -/* Render a window top border for lwthemes on WinXP modern themes: */ -@media (-moz-windows-theme: luna-blue) { - #main-window[tabsintitlebar][sizemode="normal"] > #tab-view-deck > #browser-panel:-moz-lwtheme { - background-image: linear-gradient(to bottom, - rgb(8, 49, 216) 0, rgb(8, 49, 216) 1px, - rgb(15, 77, 227) 1px, rgb(15, 77, 227) 2px, - rgb(22, 106, 238) 2px, rgb(22, 106, 238) 3px, - rgb(8, 85, 221) 3px, rgb(8, 85, 221) 4px, - transparent 4px); - } - - #main-window[tabsintitlebar][sizemode="normal"] > #tab-view-deck > #browser-panel:-moz-lwtheme:-moz-window-inactive { - background-image: linear-gradient(to bottom, - rgb(91, 104, 205) 0, rgb(91, 104, 205) 1px, - rgb(116, 128, 220) 1px, rgb(116, 128, 220) 2px, - rgb(117, 140, 221) 2px, rgb(117, 140, 221) 4px, - transparent 4px); - } -} - -@media (-moz-windows-theme: luna-silver) { - #main-window[tabsintitlebar][sizemode="normal"] > #tab-view-deck > #browser-panel:-moz-lwtheme { - background-image: linear-gradient(to bottom, - rgb(102,102,126) 0, rgb(102,102,126) 1px, - rgb(168,167,191) 1px, rgb(168,167,191) 2px, - white 2px, white 3px, - rgb(188,188,207) 3px, rgb(188,188,207) 4px, - transparent 4px); - } - - #main-window[tabsintitlebar][sizemode="normal"] > #tab-view-deck > #browser-panel:-moz-lwtheme:-moz-window-inactive { - background-image: linear-gradient(to bottom, - rgb(186,186,197) 0, rgb(186,186,197) 1px, - rgb(236,238,245) 1px, rgb(236,238,245) 2px, - white 2px, white 3px, - rgb(215,215,227) 3px, rgb(215,215,227) 4px, - transparent 4px); - } -} - -@media (-moz-windows-theme: luna-olive) { - #main-window[tabsintitlebar][sizemode="normal"] > #tab-view-deck > #browser-panel:-moz-lwtheme { - background-image: linear-gradient(to bottom, - rgb(139,161,105) 0, rgb(139,161,105) 1px, - rgb(171, 189, 133) 1px, rgb(171, 189, 133) 2px, - rgb(164,178,127) 2px, rgb(164,178,127) 3px, - transparent 3px); - } - - #main-window[tabsintitlebar][sizemode="normal"] > #tab-view-deck > #browser-panel:-moz-lwtheme:-moz-window-inactive { - background-image: linear-gradient(to bottom, - rgb(207, 214, 188) 0, rgb(207, 214, 188) 1px, - rgb(224, 226, 200) 1px, rgb(224, 226, 200) 2px, - rgb(214, 216, 190) 2px, rgb(214, 216, 190) 3px, - transparent 3px); - } -} - #TabsToolbar:not([collapsed="true"]) + #nav-bar { /* Move up into the TabsToolbar for the inner highlight at the top of the nav-bar */ margin-top: calc(-1 * var(--navbar-tab-toolbar-highlight-overlap)); @@ -406,12 +345,6 @@ toolbar:-moz-lwtheme { background-color: -moz-dialog; } -@media (-moz-os-version: windows-xp) and (-moz-windows-default-theme) { - #main-window[tabsintitlebar][sizemode="normal"] #toolbar-menubar { - margin-top: 4px; - } -} - /* ::::: titlebar ::::: */ #main-window[sizemode="normal"] > #titlebar { @@ -432,7 +365,7 @@ toolbar:-moz-lwtheme { * click and hover mouse events to work properly for the button in the restored * window state. Otherwise, elements in the navigator-toolbox, like the menubar, * can swallow those events. It will also place the buttons above the fog on - * themes with Aero Glass. + * Windows 7 with Aero Glass. */ #titlebar-buttonbox { z-index: 1; @@ -442,12 +375,6 @@ toolbar:-moz-lwtheme { margin-left: 22px; /* space needed for Aero Snap */ } -@media (-moz-os-version: windows-xp) { - .titlebar-placeholder[type="caption-buttons"] { - margin-left: 10px; /* less space needed on XP because there's no Aero Snap */ - } -} - /* titlebar command buttons */ #titlebar-min { @@ -670,13 +597,6 @@ menuitem.bookmark-item { %include ../shared/toolbarbuttons.inc.css -@media (-moz-windows-theme: luna-silver) and (max-resolution: 1dppx) { - :-moz-any(@primaryToolbarButtons@), - #bookmarks-menu-button.toolbarbutton-1 > .toolbarbutton-menubutton-dropmarker > .dropmarker-icon { - list-style-image: url("chrome://browser/skin/Toolbar-lunaSilver.png"); - } -} - #main-window:not([customizing]) .toolbarbutton-1[disabled=true] > .toolbarbutton-icon, #main-window:not([customizing]) .toolbarbutton-1[disabled=true] > .toolbarbutton-menu-dropmarker, #main-window:not([customizing]) .toolbarbutton-1[disabled=true] > .toolbarbutton-menubutton-dropmarker, @@ -780,10 +700,7 @@ toolbar[brighttext] .toolbarbutton-1 > .toolbarbutton-menubutton-dropmarker { max-width: 32px; } -@media (-moz-os-version: windows-xp), - (-moz-os-version: windows-vista), - (-moz-os-version: windows-win7) { - /* < Win8 */ +@media (-moz-os-version: windows-win7) { :root { --toolbarbutton-hover-background: linear-gradient(hsla(0,0%,100%,.6), hsla(0,0%,100%,.1)); --toolbarbutton-hover-bordercolor: hsla(210,54%,20%,.15) hsla(210,54%,20%,.2) hsla(210,54%,20%,.25); @@ -1101,9 +1018,7 @@ toolbar[brighttext] #close-button { list-style-image: url(chrome://browser/skin/caption-buttons.svg#close-white); } -@media (-moz-os-version: windows-xp), - (-moz-os-version: windows-vista), - (-moz-os-version: windows-win7) { +@media (-moz-os-version: windows-win7) { #window-controls { margin-inline-start: 4px; } @@ -1159,8 +1074,7 @@ toolbar[brighttext] #close-button { } } -@media (-moz-os-version: windows-vista), - (-moz-os-version: windows-win7) { +@media (-moz-os-version: windows-win7) { #window-controls { -moz-box-align: start; } @@ -1204,8 +1118,7 @@ toolbar[brighttext] #close-button { } @media (-moz-windows-default-theme) { - @media (-moz-os-version: windows-vista), - (-moz-os-version: windows-win7), + @media (-moz-os-version: windows-win7), (-moz-os-version: windows-win8) { #main-window:not(:-moz-lwtheme) { --urlbar-border-color: hsla(210,54%,20%,.25) hsla(210,54%,20%,.27) hsla(210,54%,20%,.3); @@ -1242,8 +1155,7 @@ toolbar[brighttext] #close-button { border-radius: 1px; } - @media (-moz-os-version: windows-vista), - (-moz-os-version: windows-win7), + @media (-moz-os-version: windows-win7), (-moz-os-version: windows-win8) { #urlbar:not(:-moz-lwtheme), .searchbar-textbox:not(:-moz-lwtheme) { @@ -1266,11 +1178,9 @@ toolbar[brighttext] #close-button { } } - @media not all and (-moz-os-version: windows-xp) { - #urlbar:not(:-moz-lwtheme)[focused], - .searchbar-textbox:not(:-moz-lwtheme)[focused] { - border-color: Highlight; - } + #urlbar:not(:-moz-lwtheme)[focused], + .searchbar-textbox:not(:-moz-lwtheme)[focused] { + border-color: Highlight; } } @@ -2023,9 +1933,7 @@ html|span.ac-emphasize-text-url { } } -@media (-moz-os-version: windows-xp), - (-moz-os-version: windows-vista), - (-moz-os-version: windows-win7) { +@media (-moz-os-version: windows-win7) { #sidebar-header > .close-icon { padding-top: 4px; padding-bottom: 4px; @@ -2046,39 +1954,28 @@ html|span.ac-emphasize-text-url { margin-bottom: calc(-1 * var(--tab-toolbar-navbar-overlap)); /* overlap the nav-bar's top border */ } -@media (-moz-os-version: windows-xp) and (-moz-windows-default-theme) { - #main-window[sizemode=normal] #TabsToolbar { - padding-left: 2px; - padding-right: 2px; - } -} - %include ../shared/tabs.inc.css /* Remove border between tab strip and navigation toolbar on Windows 10+ */ -@media not all and (-moz-os-version: windows-xp) { - @media not all and (-moz-os-version: windows-vista) { - @media not all and (-moz-os-version: windows-win7) { - @media not all and (-moz-os-version: windows-win8) { - @media (-moz-windows-default-theme) { - .tab-background-end[selected=true]::after, - .tab-background-start[selected=true]::after { - content: none; - } - - #TabsToolbar { - --tab-stroke-background-size: 0 0; - } - - :root { - --tab-toolbar-navbar-overlap: 0px; - } - - #nav-bar { - border-top-style: none !important; - box-shadow: none; - } - } +@media not all and (-moz-os-version: windows-win7) { + @media not all and (-moz-os-version: windows-win8) { + @media (-moz-windows-default-theme) { + .tab-background-end[selected=true]::after, + .tab-background-start[selected=true]::after { + content: none; + } + + #TabsToolbar { + --tab-stroke-background-size: 0 0; + } + + :root { + --tab-toolbar-navbar-overlap: 0px; + } + + #nav-bar { + border-top-style: none !important; + box-shadow: none; } } } @@ -2563,22 +2460,6 @@ notification.pluginVulnerable > .notification-inner > .messageCloseButton { position: relative; } -@media (-moz-os-version: windows-xp) { - @media not all and (-moz-windows-classic) { - #private-browsing-indicator-titlebar > .private-browsing-indicator { - background-image: url("chrome://browser/skin/privatebrowsing-mask-titlebar-XPVista7-tall.png"); - height: 28px; - } - - #main-window[sizemode="maximized"] > #titlebar > #titlebar-content > #titlebar-buttonbox-container > #private-browsing-indicator-titlebar > .private-browsing-indicator { - top: -5px; - } - #main-window[sizemode="normal"] > #titlebar > #titlebar-content > #titlebar-buttonbox-container > #private-browsing-indicator-titlebar > .private-browsing-indicator { - top: -1px; - } - } -} - @media (-moz-windows-classic) { /** * We have to use top instead of background-position in this case, otherwise @@ -2590,8 +2471,7 @@ notification.pluginVulnerable > .notification-inner > .messageCloseButton { } } -@media (-moz-os-version: windows-vista), - (-moz-os-version: windows-win7) { +@media (-moz-os-version: windows-win7) { @media (-moz-windows-glass) { #main-window[sizemode="normal"] > #titlebar > #titlebar-content > #titlebar-buttonbox-container > #private-browsing-indicator-titlebar > .private-browsing-indicator { top: 1px; @@ -2608,7 +2488,7 @@ notification.pluginVulnerable > .notification-inner > .messageCloseButton { @media (-moz-windows-default-theme) { @media not all and (-moz-windows-compositor) { #main-window[sizemode="normal"] > #titlebar > #titlebar-content > #titlebar-buttonbox-container > #private-browsing-indicator-titlebar > .private-browsing-indicator { - background-image: url("chrome://browser/skin/privatebrowsing-mask-titlebar-XPVista7-tall.png"); + background-image: url("chrome://browser/skin/privatebrowsing-mask-titlebar-win7-tall.png"); height: 28px; } } @@ -2641,19 +2521,14 @@ notification.pluginVulnerable > .notification-inner > .messageCloseButton { margin-top: -4px; } - -@media not all and (-moz-os-version: windows-xp) { %include browser-aero.css -} .browser-extension-panel > .panel-arrowcontainer > .panel-arrowcontent { padding: 0; overflow: hidden; } -@media (-moz-os-version: windows-xp), - (-moz-os-version: windows-vista), - (-moz-os-version: windows-win7) { +@media (-moz-os-version: windows-win7) { .cui-widget-panelview[id^=PanelUI-webext-] { border-radius: 4px; } diff --git a/browser/themes/windows/customizableui/panelUI.css b/browser/themes/windows/customizableui/panelUI.css index 92080d5998..189a163f3f 100644 --- a/browser/themes/windows/customizableui/panelUI.css +++ b/browser/themes/windows/customizableui/panelUI.css @@ -131,21 +131,17 @@ menu.subviewbutton > .menu-right:-moz-locale-dir(rtl) { } /* Win8 and beyond. */ -@media not all and (-moz-os-version: windows-xp) { - @media not all and (-moz-os-version: windows-vista) { - @media not all and (-moz-os-version: windows-win7) { - panelview .toolbarbutton-1, - .subviewbutton, - .widget-overflow-list .toolbarbutton-1, - .panelUI-grid .toolbarbutton-1 > .toolbarbutton-menubutton-button, - #BMB_bookmarksPopup menupopup[placespopup=true] > hbox, - #edit-controls@inAnyPanel@, - #zoom-controls@inAnyPanel@, - #edit-controls@inAnyPanel@ > toolbarbutton, - #zoom-controls@inAnyPanel@ > toolbarbutton { - border-radius: 0; - } - } +@media not all and (-moz-os-version: windows-win7) { + panelview .toolbarbutton-1, + .subviewbutton, + .widget-overflow-list .toolbarbutton-1, + .panelUI-grid .toolbarbutton-1 > .toolbarbutton-menubutton-button, + #BMB_bookmarksPopup menupopup[placespopup=true] > hbox, + #edit-controls@inAnyPanel@, + #zoom-controls@inAnyPanel@, + #edit-controls@inAnyPanel@ > toolbarbutton, + #zoom-controls@inAnyPanel@ > toolbarbutton { + border-radius: 0; } } diff --git a/browser/themes/windows/devedition.css b/browser/themes/windows/devedition.css index 2dc72eeeb3..bdf4bb80e5 100644 --- a/browser/themes/windows/devedition.css +++ b/browser/themes/windows/devedition.css @@ -16,7 +16,7 @@ /* The window background is white due to no accentcolor in the lightweight theme. It can't be changed to transparent when there is no compositor - (Win XP or 7 in classic / basic theme), or else dragging and focus become + (Win 7 in classic / basic theme), or else dragging and focus become broken. So instead just show the normal titlebar in that case, and override the window color as transparent when the compositor is available. */ @media not all and (-moz-windows-compositor) { @@ -116,9 +116,7 @@ } } -@media (-moz-os-version: windows-xp), - (-moz-os-version: windows-vista), - (-moz-os-version: windows-win7), +@media (-moz-os-version: windows-win7), (-moz-os-version: windows-win8) { :root { --space-above-tabbar: 15px; @@ -261,8 +259,7 @@ color: var(--chrome-color); } -@media (-moz-os-version: windows-vista), - (-moz-os-version: windows-win7), +@media (-moz-os-version: windows-win7), (-moz-os-version: windows-win8) { /* And then we add them back on toolbars so that they don't look borderless: */ #main-window:not([customizing])[sizemode=normal] #navigator-toolbox::after, diff --git a/browser/themes/windows/downloads/allDownloadsViewOverlay.css b/browser/themes/windows/downloads/allDownloadsViewOverlay.css index e288f1e909..0ee83f669f 100644 --- a/browser/themes/windows/downloads/allDownloadsViewOverlay.css +++ b/browser/themes/windows/downloads/allDownloadsViewOverlay.css @@ -18,32 +18,30 @@ /*** Highlighted list items ***/ -@media not all and (-moz-os-version: windows-xp) { - @media (-moz-windows-default-theme) { - /* - -moz-appearance: menuitem is almost right, but the hover effect is not - transparent and is lighter than desired. - - Copied from the autocomplete richlistbox styling in - toolkit/themes/windows/global/autocomplete.css - - This styling should be kept in sync with the style from the above file. - */ - @itemFocused@ { - color: inherit; - background-color: transparent; - /* four gradients for the bevel highlights on each edge, one for blue background */ - background-image: - linear-gradient(to bottom, rgba(255,255,255,0.9) 3px, transparent 3px), - linear-gradient(to right, rgba(255,255,255,0.5) 3px, transparent 3px), - linear-gradient(to left, rgba(255,255,255,0.5) 3px, transparent 3px), - linear-gradient(to top, rgba(255,255,255,0.4) 3px, transparent 3px), - linear-gradient(to bottom, rgba(163,196,247,0.3), rgba(122,180,246,0.3)); - background-clip: content-box; - border-radius: 6px; - outline: 1px solid rgb(124,163,206); - -moz-outline-radius: 3px; - outline-offset: -2px; - } +@media (-moz-windows-default-theme) { + /* + -moz-appearance: menuitem is almost right, but the hover effect is not + transparent and is lighter than desired. + + Copied from the autocomplete richlistbox styling in + toolkit/themes/windows/global/autocomplete.css + + This styling should be kept in sync with the style from the above file. + */ + @itemFocused@ { + color: inherit; + background-color: transparent; + /* four gradients for the bevel highlights on each edge, one for blue background */ + background-image: + linear-gradient(to bottom, rgba(255,255,255,0.9) 3px, transparent 3px), + linear-gradient(to right, rgba(255,255,255,0.5) 3px, transparent 3px), + linear-gradient(to left, rgba(255,255,255,0.5) 3px, transparent 3px), + linear-gradient(to top, rgba(255,255,255,0.4) 3px, transparent 3px), + linear-gradient(to bottom, rgba(163,196,247,0.3), rgba(122,180,246,0.3)); + background-clip: content-box; + border-radius: 6px; + outline: 1px solid rgb(124,163,206); + -moz-outline-radius: 3px; + outline-offset: -2px; } } diff --git a/browser/themes/windows/downloads/download-glow-menuPanel-XPVista7.png b/browser/themes/windows/downloads/download-glow-menuPanel-win7.png Binary files differindex 7ff7e6a033..7ff7e6a033 100644 --- a/browser/themes/windows/downloads/download-glow-menuPanel-XPVista7.png +++ b/browser/themes/windows/downloads/download-glow-menuPanel-win7.png diff --git a/browser/themes/windows/downloads/download-glow-XPVista7.png b/browser/themes/windows/downloads/download-glow-win7.png Binary files differindex e7415e83d8..e7415e83d8 100644 --- a/browser/themes/windows/downloads/download-glow-XPVista7.png +++ b/browser/themes/windows/downloads/download-glow-win7.png diff --git a/browser/themes/windows/downloads/indicator.css b/browser/themes/windows/downloads/indicator.css index 6272650881..7f921f8def 100644 --- a/browser/themes/windows/downloads/indicator.css +++ b/browser/themes/windows/downloads/indicator.css @@ -166,13 +166,9 @@ toolbar[brighttext] #downloads-button:not([counter])[attention="success"] > #dow font-size: 9px; line-height: 9px; text-align: center; -} -@media not all and (-moz-os-version: windows-xp) { - #downloads-indicator-counter { - /* Bug 812345 added this... */ - margin-bottom: -1px; - } + /* Bug 812345 added this... */ + margin-bottom: -1px; } toolbar[brighttext] #downloads-indicator-counter { diff --git a/browser/themes/windows/feeds/feedIcon-XP.png b/browser/themes/windows/feeds/feedIcon-XP.png Binary files differdeleted file mode 100644 index d0cafb1d4a..0000000000 --- a/browser/themes/windows/feeds/feedIcon-XP.png +++ /dev/null diff --git a/browser/themes/windows/feeds/feedIcon16-XP.png b/browser/themes/windows/feeds/feedIcon16-XP.png Binary files differdeleted file mode 100644 index dd7821f8dc..0000000000 --- a/browser/themes/windows/feeds/feedIcon16-XP.png +++ /dev/null diff --git a/browser/themes/windows/jar.mn b/browser/themes/windows/jar.mn index 89c589abad..10abfd001f 100644 --- a/browser/themes/windows/jar.mn +++ b/browser/themes/windows/jar.mn @@ -11,21 +11,17 @@ browser.jar: * skin/classic/browser/syncedtabs/sidebar.css (syncedtabs/sidebar.css) skin/classic/browser/actionicon-tab.png skin/classic/browser/actionicon-tab@2x.png - skin/classic/browser/actionicon-tab-XPVista7.png + skin/classic/browser/actionicon-tab-win7.png * skin/classic/browser/browser.css * skin/classic/browser/devedition.css * skin/classic/browser/browser-lightweightTheme.css skin/classic/browser/caption-buttons.svg skin/classic/browser/click-to-play-warning-stripes.png skin/classic/browser/Info.png - skin/classic/browser/Info-XP.png skin/classic/browser/keyhole-forward-mask.svg skin/classic/browser/livemark-folder.png - skin/classic/browser/livemark-folder-XP.png skin/classic/browser/menu-back.png - skin/classic/browser/menu-back-XP.png skin/classic/browser/menu-forward.png - skin/classic/browser/menu-forward-XP.png skin/classic/browser/menuPanel-customize.png skin/classic/browser/menuPanel-customize@2x.png skin/classic/browser/menuPanel-exit.png @@ -36,36 +32,33 @@ browser.jar: skin/classic/browser/monitor_16-10.png skin/classic/browser/pageInfo.css skin/classic/browser/pageInfo.png - skin/classic/browser/pageInfo-XP.png skin/classic/browser/privatebrowsing-mask-tabstrip.png - skin/classic/browser/privatebrowsing-mask-tabstrip-XPVista7.png + skin/classic/browser/privatebrowsing-mask-tabstrip-win7.png skin/classic/browser/privatebrowsing-mask-titlebar.png - skin/classic/browser/privatebrowsing-mask-titlebar-XPVista7.png - skin/classic/browser/privatebrowsing-mask-titlebar-XPVista7-tall.png + skin/classic/browser/privatebrowsing-mask-titlebar-win7.png + skin/classic/browser/privatebrowsing-mask-titlebar-win7-tall.png skin/classic/browser/reload-stop-go.png skin/classic/browser/reload-stop-go@2x.png - skin/classic/browser/reload-stop-go-XPVista7.png - skin/classic/browser/reload-stop-go-XPVista7@2x.png + skin/classic/browser/reload-stop-go-win7.png + skin/classic/browser/reload-stop-go-win7@2x.png skin/classic/browser/searchbar.css skin/classic/browser/setDesktopBackground.css skin/classic/browser/slowStartup-16.png skin/classic/browser/Toolbar.png skin/classic/browser/Toolbar@2x.png - skin/classic/browser/Toolbar-aero.png - skin/classic/browser/Toolbar-aero@2x.png + skin/classic/browser/Toolbar-win7.png + skin/classic/browser/Toolbar-win7@2x.png skin/classic/browser/Toolbar-inverted.png skin/classic/browser/Toolbar-inverted@2x.png - skin/classic/browser/Toolbar-lunaSilver.png skin/classic/browser/Toolbar-win8.png skin/classic/browser/Toolbar-win8@2x.png - skin/classic/browser/Toolbar-XP.png - skin/classic/browser/toolbarbutton-dropdown-arrow-XPVista7.png + skin/classic/browser/toolbarbutton-dropdown-arrow-win7.png skin/classic/browser/toolbarbutton-dropdown-arrow-inverted.png skin/classic/browser/urlbar-popup-blocked.png skin/classic/browser/urlbar-history-dropmarker.png skin/classic/browser/urlbar-history-dropmarker@2x.png - skin/classic/browser/urlbar-history-dropmarker-XPVista7.png - skin/classic/browser/urlbar-history-dropmarker-XPVista7@2x.png + skin/classic/browser/urlbar-history-dropmarker-win7.png + skin/classic/browser/urlbar-history-dropmarker-win7@2x.png skin/classic/browser/webRTC-indicator.css * skin/classic/browser/controlcenter/panel.css (controlcenter/panel.css) skin/classic/browser/customizableui/background-noise-toolbar.png (customizableui/background-noise-toolbar.png) @@ -78,57 +71,40 @@ browser.jar: * skin/classic/browser/customizableui/panelUI.css (customizableui/panelUI.css) * skin/classic/browser/downloads/allDownloadsViewOverlay.css (downloads/allDownloadsViewOverlay.css) skin/classic/browser/downloads/download-glow-menuPanel.png (downloads/download-glow-menuPanel.png) - skin/classic/browser/downloads/download-glow-menuPanel-XPVista7.png (downloads/download-glow-menuPanel-XPVista7.png) + skin/classic/browser/downloads/download-glow-menuPanel-win7.png (downloads/download-glow-menuPanel-win7.png) skin/classic/browser/downloads/download-notification-finish.png (downloads/download-notification-finish.png) skin/classic/browser/downloads/download-notification-start.png (downloads/download-notification-start.png) * skin/classic/browser/downloads/downloads.css (downloads/downloads.css) skin/classic/browser/feeds/feedIcon.png (feeds/feedIcon.png) skin/classic/browser/feeds/feedIcon16.png (feeds/feedIcon16.png) - skin/classic/browser/feeds/feedIcon-XP.png (feeds/feedIcon-XP.png) - skin/classic/browser/feeds/feedIcon16-XP.png (feeds/feedIcon16-XP.png) skin/classic/browser/feeds/subscribe.css (feeds/subscribe.css) skin/classic/browser/feeds/subscribe-ui.css (feeds/subscribe-ui.css) * skin/classic/browser/newtab/newTab.css (newtab/newTab.css) skin/classic/browser/places/autocomplete-star.png (places/autocomplete-star.png) skin/classic/browser/places/autocomplete-star@2x.png (places/autocomplete-star@2x.png) - skin/classic/browser/places/autocomplete-star-XPVista7.png (places/autocomplete-star-XPVista7.png) + skin/classic/browser/places/autocomplete-star-win7.png (places/autocomplete-star-win7.png) skin/classic/browser/places/places.css (places/places.css) * skin/classic/browser/places/organizer.css (places/organizer.css) skin/classic/browser/places/query.png (places/query.png) - skin/classic/browser/places/query-XP.png (places/query-XP.png) skin/classic/browser/places/bookmarksMenu.png (places/bookmarksMenu.png) - skin/classic/browser/places/bookmarksMenu-XP.png (places/bookmarksMenu-XP.png) skin/classic/browser/places/bookmarksToolbar.png (places/bookmarksToolbar.png) - skin/classic/browser/places/bookmarksToolbar-XP.png (places/bookmarksToolbar-XP.png) skin/classic/browser/places/bookmarksToolbar-menuPanel.png (places/bookmarksToolbar-menuPanel.png) - skin/classic/browser/places/bookmarksToolbar-menuPanel-XP.png (places/bookmarksToolbar-menuPanel-XP.png) skin/classic/browser/places/bookmarks-notification-finish.png (places/bookmarks-notification-finish.png) skin/classic/browser/places/calendar.png (places/calendar.png) - skin/classic/browser/places/calendar-XP.png (places/calendar-XP.png) skin/classic/browser/places/toolbarDropMarker.png (places/toolbarDropMarker.png) - skin/classic/browser/places/toolbarDropMarker-XP.png (places/toolbarDropMarker-XP.png) skin/classic/browser/places/editBookmarkOverlay.css (places/editBookmarkOverlay.css) skin/classic/browser/places/libraryToolbar.png (places/libraryToolbar.png) - skin/classic/browser/places/libraryToolbar-XP.png (places/libraryToolbar-XP.png) skin/classic/browser/places/starred48.png (places/starred48.png) - skin/classic/browser/places/starred48-XP.png (places/starred48-XP.png) skin/classic/browser/places/unstarred48.png (places/unstarred48.png) skin/classic/browser/places/tag.png (places/tag.png) - skin/classic/browser/places/tag-XP.png (places/tag-XP.png) skin/classic/browser/places/history.png (places/history.png) - skin/classic/browser/places/history-XP.png (places/history-XP.png) skin/classic/browser/places/allBookmarks.png (places/allBookmarks.png) - skin/classic/browser/places/allBookmarks-XP.png (places/allBookmarks-XP.png) skin/classic/browser/places/unsortedBookmarks.png (places/unsortedBookmarks.png) - skin/classic/browser/places/unsortedBookmarks-XP.png (places/unsortedBookmarks-XP.png) skin/classic/browser/places/downloads.png (places/downloads.png) skin/classic/browser/places/livemark-item.png (places/livemark-item.png) skin/classic/browser/preferences/alwaysAsk.png (preferences/alwaysAsk.png) - skin/classic/browser/preferences/alwaysAsk-XP.png (preferences/alwaysAsk-XP.png) skin/classic/browser/preferences/application.png (preferences/application.png) - skin/classic/browser/preferences/application-XP.png (preferences/application-XP.png) skin/classic/browser/preferences/saveFile.png (preferences/saveFile.png) - skin/classic/browser/preferences/saveFile-XP.png (preferences/saveFile-XP.png) skin/classic/browser/preferences/preferences.css (preferences/preferences.css) * skin/classic/browser/preferences/in-content/preferences.css (preferences/in-content/preferences.css) * skin/classic/browser/preferences/in-content/dialog.css (preferences/in-content/dialog.css) @@ -136,13 +112,13 @@ browser.jar: skin/classic/browser/social/services-16.png (social/services-16.png) skin/classic/browser/social/services-64.png (social/services-64.png) skin/classic/browser/tabbrowser/newtab.svg (tabbrowser/newtab.svg) - skin/classic/browser/tabbrowser/newtab-XPVista7.svg (tabbrowser/newtab-XPVista7.svg) + skin/classic/browser/tabbrowser/newtab-win7.svg (tabbrowser/newtab-win7.svg) skin/classic/browser/tabbrowser/newtab-inverted.svg (tabbrowser/newtab-inverted.svg) - skin/classic/browser/tabbrowser/newtab-inverted-XPVista7.svg (tabbrowser/newtab-inverted-XPVista7.svg) + skin/classic/browser/tabbrowser/newtab-inverted-win7.svg (tabbrowser/newtab-inverted-win7.svg) skin/classic/browser/tabbrowser/tab-active-middle.png (tabbrowser/tab-active-middle.png) skin/classic/browser/tabbrowser/tab-active-middle@2x.png (tabbrowser/tab-active-middle@2x.png) skin/classic/browser/tabbrowser/tab-arrow-left.svg (tabbrowser/tab-arrow-left.svg) - skin/classic/browser/tabbrowser/tab-arrow-left-XPVista7.svg (tabbrowser/tab-arrow-left-XPVista7.svg) + skin/classic/browser/tabbrowser/tab-arrow-left-win7.svg (tabbrowser/tab-arrow-left-win7.svg) skin/classic/browser/tabbrowser/tab-arrow-left-inverted.svg (tabbrowser/tab-arrow-left-inverted.svg) skin/classic/browser/tabbrowser/tab-background-start.png (tabbrowser/tab-background-start.png) skin/classic/browser/tabbrowser/tab-background-start@2x.png (tabbrowser/tab-background-start@2x.png) @@ -174,8 +150,8 @@ browser.jar: skin/classic/browser/sync-desktopIcon.svg (../shared/sync-desktopIcon.svg) skin/classic/browser/sync-horizontalbar.png skin/classic/browser/sync-horizontalbar@2x.png - skin/classic/browser/sync-horizontalbar-XPVista7.png - skin/classic/browser/sync-horizontalbar-XPVista7@2x.png + skin/classic/browser/sync-horizontalbar-win7.png + skin/classic/browser/sync-horizontalbar-win7@2x.png skin/classic/browser/sync-mobileIcon.svg (../shared/sync-mobileIcon.svg) skin/classic/browser/sync-notification-24.png skin/classic/browser/syncSetup.css @@ -183,16 +159,16 @@ browser.jar: skin/classic/browser/syncQuota.css skin/classic/browser/syncProgress-horizontalbar.png skin/classic/browser/syncProgress-horizontalbar@2x.png - skin/classic/browser/syncProgress-horizontalbar-XPVista7.png - skin/classic/browser/syncProgress-horizontalbar-XPVista7@2x.png + skin/classic/browser/syncProgress-horizontalbar-win7.png + skin/classic/browser/syncProgress-horizontalbar-win7@2x.png skin/classic/browser/syncProgress-menuPanel.png skin/classic/browser/syncProgress-menuPanel@2x.png skin/classic/browser/syncProgress-toolbar.png skin/classic/browser/syncProgress-toolbar@2x.png skin/classic/browser/syncProgress-toolbar-inverted.png skin/classic/browser/syncProgress-toolbar-inverted@2x.png - skin/classic/browser/syncProgress-toolbar-XPVista7.png - skin/classic/browser/syncProgress-toolbar-XPVista7@2x.png + skin/classic/browser/syncProgress-toolbar-win7.png + skin/classic/browser/syncProgress-toolbar-win7@2x.png #ifdef E10S_TESTING_ONLY skin/classic/browser/e10s-64@2x.png (../shared/e10s-64@2x.png) #endif @@ -205,58 +181,31 @@ browser.jar: % override chrome://browser/skin/feeds/videoFeedIcon16.png chrome://browser/skin/feeds/feedIcon16.png % override chrome://browser/skin/aboutSessionRestore-window-icon.png chrome://browser/skin/preferences/application.png os!=WINNT -% override chrome://browser/skin/aboutSessionRestore-window-icon.png chrome://browser/skin/preferences/application.png os=WINNT osversion<6 -% override chrome://browser/skin/Info.png chrome://browser/skin/Info-XP.png os=WINNT osversion<6 -% override chrome://browser/skin/livemark-folder.png chrome://browser/skin/livemark-folder-XP.png os=WINNT osversion<6 -% override chrome://browser/skin/menu-back.png chrome://browser/skin/menu-back-XP.png os=WINNT osversion<6 -% override chrome://browser/skin/menu-forward.png chrome://browser/skin/menu-forward-XP.png os=WINNT osversion<6 -% override chrome://browser/skin/pageInfo.png chrome://browser/skin/pageInfo-XP.png os=WINNT osversion<6 -% override chrome://browser/skin/feeds/feedIcon.png chrome://browser/skin/feeds/feedIcon-XP.png os=WINNT osversion<6 -% override chrome://browser/skin/feeds/feedIcon16.png chrome://browser/skin/feeds/feedIcon16-XP.png os=WINNT osversion<6 -% override chrome://browser/skin/places/query.png chrome://browser/skin/places/query-XP.png os=WINNT osversion<6 -% override chrome://browser/skin/places/bookmarksMenu.png chrome://browser/skin/places/bookmarksMenu-XP.png os=WINNT osversion<6 -% override chrome://browser/skin/places/bookmarksToolbar.png chrome://browser/skin/places/bookmarksToolbar-XP.png os=WINNT osversion<6 -% override chrome://browser/skin/places/bookmarksToolbar-menuPanel.png chrome://browser/skin/places/bookmarksToolbar-menuPanel-XP.png os=WINNT osversion<6 -% override chrome://browser/skin/places/calendar.png chrome://browser/skin/places/calendar-XP.png os=WINNT osversion<6 -% override chrome://browser/skin/places/toolbarDropMarker.png chrome://browser/skin/places/toolbarDropMarker-XP.png os=WINNT osversion<6 -% override chrome://browser/skin/places/libraryToolbar.png chrome://browser/skin/places/libraryToolbar-XP.png os=WINNT osversion<6 -% override chrome://browser/skin/places/starred48.png chrome://browser/skin/places/starred48-XP.png os=WINNT osversion<6 -% override chrome://browser/skin/places/tag.png chrome://browser/skin/places/tag-XP.png os=WINNT osversion<6 -% override chrome://browser/skin/places/history.png chrome://browser/skin/places/history-XP.png os=WINNT osversion<6 -% override chrome://browser/skin/places/allBookmarks.png chrome://browser/skin/places/allBookmarks-XP.png os=WINNT osversion<6 -% override chrome://browser/skin/places/unsortedBookmarks.png chrome://browser/skin/places/unsortedBookmarks-XP.png os=WINNT osversion<6 -% override chrome://browser/skin/preferences/alwaysAsk.png chrome://browser/skin/preferences/alwaysAsk-XP.png os=WINNT osversion<6 -% override chrome://browser/skin/preferences/application.png chrome://browser/skin/preferences/application-XP.png os=WINNT osversion<6 -% override chrome://browser/skin/preferences/saveFile.png chrome://browser/skin/preferences/saveFile-XP.png os=WINNT osversion<6 +% override chrome://browser/skin/actionicon-tab.png chrome://browser/skin/actionicon-tab-win7.png os=WINNT osversion<=6.1 +% override chrome://browser/skin/privatebrowsing-mask-tabstrip.png chrome://browser/skin/privatebrowsing-mask-tabstrip-win7.png os=WINNT osversion<=6.1 +% override chrome://browser/skin/privatebrowsing-mask-titlebar.png chrome://browser/skin/privatebrowsing-mask-titlebar-win7.png os=WINNT osversion<=6.1 +% override chrome://browser/skin/reload-stop-go.png chrome://browser/skin/reload-stop-go-win7.png os=WINNT osversion<=6.1 +% override chrome://browser/skin/reload-stop-go@2x.png chrome://browser/skin/reload-stop-go-win7@2x.png os=WINNT osversion<=6.1 +% override chrome://browser/skin/sync-horizontalbar.png chrome://browser/skin/sync-horizontalbar-win7.png os=WINNT osversion<=6.1 +% override chrome://browser/skin/sync-horizontalbar@2x.png chrome://browser/skin/sync-horizontalbar-win7@2x.png os=WINNT osversion<=6.1 +% override chrome://browser/skin/syncProgress-horizontalbar.png chrome://browser/skin/syncProgress-horizontalbar-win7.png os=WINNT osversion<=6.1 +% override chrome://browser/skin/syncProgress-horizontalbar@2x.png chrome://browser/skin/syncProgress-horizontalbar-win7@2x.png os=WINNT osversion<=6.1 +% override chrome://browser/skin/syncProgress-toolbar.png chrome://browser/skin/syncProgress-toolbar-win7.png os=WINNT osversion<=6.1 +% override chrome://browser/skin/syncProgress-toolbar@2x.png chrome://browser/skin/syncProgress-toolbar-win7@2x.png os=WINNT osversion<=6.1 +% override chrome://browser/skin/toolbarbutton-dropdown-arrow.png chrome://browser/skin/toolbarbutton-dropdown-arrow-win7.png os=WINNT osversion<=6.1 +% override chrome://browser/skin/urlbar-history-dropmarker.png chrome://browser/skin/urlbar-history-dropmarker-win7.png os=WINNT osversion<=6.1 +% override chrome://browser/skin/urlbar-history-dropmarker@2x.png chrome://browser/skin/urlbar-history-dropmarker-win7@2x.png os=WINNT osversion<=6.1 +% override chrome://browser/skin/downloads/download-glow-menuPanel.png chrome://browser/skin/downloads/download-glow-menuPanel-win7.png os=WINNT osversion<=6.1 +% override chrome://browser/skin/places/autocomplete-star.png chrome://browser/skin/places/autocomplete-star-win7.png os=WINNT osversion<=6.1 +% override chrome://browser/skin/tabbrowser/newtab.svg chrome://browser/skin/tabbrowser/newtab-win7.svg os=WINNT osversion<=6.1 +% override chrome://browser/skin/tabbrowser/newtab-inverted.svg chrome://browser/skin/tabbrowser/newtab-inverted-win7.svg os=WINNT osversion<=6.1 +% override chrome://browser/skin/tabbrowser/tab-arrow-left.svg chrome://browser/skin/tabbrowser/tab-arrow-left-win7.svg os=WINNT osversion<=6.1 -% override chrome://browser/skin/actionicon-tab.png chrome://browser/skin/actionicon-tab-XPVista7.png os=WINNT osversion<=6.1 -% override chrome://browser/skin/privatebrowsing-mask-tabstrip.png chrome://browser/skin/privatebrowsing-mask-tabstrip-XPVista7.png os=WINNT osversion<=6.1 -% override chrome://browser/skin/privatebrowsing-mask-titlebar.png chrome://browser/skin/privatebrowsing-mask-titlebar-XPVista7.png os=WINNT osversion<=6.1 -% override chrome://browser/skin/reload-stop-go.png chrome://browser/skin/reload-stop-go-XPVista7.png os=WINNT osversion<=6.1 -% override chrome://browser/skin/reload-stop-go@2x.png chrome://browser/skin/reload-stop-go-XPVista7@2x.png os=WINNT osversion<=6.1 -% override chrome://browser/skin/sync-horizontalbar.png chrome://browser/skin/sync-horizontalbar-XPVista7.png os=WINNT osversion<=6.1 -% override chrome://browser/skin/sync-horizontalbar@2x.png chrome://browser/skin/sync-horizontalbar-XPVista7@2x.png os=WINNT osversion<=6.1 -% override chrome://browser/skin/syncProgress-horizontalbar.png chrome://browser/skin/syncProgress-horizontalbar-XPVista7.png os=WINNT osversion<=6.1 -% override chrome://browser/skin/syncProgress-horizontalbar@2x.png chrome://browser/skin/syncProgress-horizontalbar-XPVista7@2x.png os=WINNT osversion<=6.1 -% override chrome://browser/skin/syncProgress-toolbar.png chrome://browser/skin/syncProgress-toolbar-XPVista7.png os=WINNT osversion<=6.1 -% override chrome://browser/skin/syncProgress-toolbar@2x.png chrome://browser/skin/syncProgress-toolbar-XPVista7@2x.png os=WINNT osversion<=6.1 -% override chrome://browser/skin/toolbarbutton-dropdown-arrow.png chrome://browser/skin/toolbarbutton-dropdown-arrow-XPVista7.png os=WINNT osversion<=6.1 -% override chrome://browser/skin/urlbar-history-dropmarker.png chrome://browser/skin/urlbar-history-dropmarker-XPVista7.png os=WINNT osversion<=6.1 -% override chrome://browser/skin/urlbar-history-dropmarker@2x.png chrome://browser/skin/urlbar-history-dropmarker-XPVista7@2x.png os=WINNT osversion<=6.1 -% override chrome://browser/skin/downloads/download-glow-menuPanel.png chrome://browser/skin/downloads/download-glow-menuPanel-XPVista7.png os=WINNT osversion<=6.1 -% override chrome://browser/skin/places/autocomplete-star.png chrome://browser/skin/places/autocomplete-star-XPVista7.png os=WINNT osversion<=6.1 -% override chrome://browser/skin/tabbrowser/newtab.svg chrome://browser/skin/tabbrowser/newtab-XPVista7.svg os=WINNT osversion<=6.1 -% override chrome://browser/skin/tabbrowser/newtab-inverted.svg chrome://browser/skin/tabbrowser/newtab-inverted-XPVista7.svg os=WINNT osversion<=6.1 -% override chrome://browser/skin/tabbrowser/tab-arrow-left.svg chrome://browser/skin/tabbrowser/tab-arrow-left-XPVista7.svg os=WINNT osversion<=6.1 - -% override chrome://browser/skin/Toolbar@2x.png chrome://browser/skin/Toolbar-aero@2x.png os=WINNT osversion=6 -% override chrome://browser/skin/Toolbar@2x.png chrome://browser/skin/Toolbar-aero@2x.png os=WINNT osversion=6.1 +% override chrome://browser/skin/Toolbar@2x.png chrome://browser/skin/Toolbar-win7@2x.png os=WINNT osversion=6.1 % override chrome://browser/skin/Toolbar@2x.png chrome://browser/skin/Toolbar-win8@2x.png os=WINNT osversion=6.2 % override chrome://browser/skin/Toolbar@2x.png chrome://browser/skin/Toolbar-win8@2x.png os=WINNT osversion=6.3 -% override chrome://browser/skin/Toolbar.png chrome://browser/skin/Toolbar-XP.png os=WINNT osversion<6 -% override chrome://browser/skin/Toolbar.png chrome://browser/skin/Toolbar-aero.png os=WINNT osversion=6 -% override chrome://browser/skin/Toolbar.png chrome://browser/skin/Toolbar-aero.png os=WINNT osversion=6.1 +% override chrome://browser/skin/Toolbar.png chrome://browser/skin/Toolbar-win7.png os=WINNT osversion=6.1 % override chrome://browser/skin/Toolbar.png chrome://browser/skin/Toolbar-win8.png os=WINNT osversion=6.2 % override chrome://browser/skin/Toolbar.png chrome://browser/skin/Toolbar-win8.png os=WINNT osversion=6.3 diff --git a/browser/themes/windows/livemark-folder-XP.png b/browser/themes/windows/livemark-folder-XP.png Binary files differdeleted file mode 100644 index 00aa0364d3..0000000000 --- a/browser/themes/windows/livemark-folder-XP.png +++ /dev/null diff --git a/browser/themes/windows/menu-back-XP.png b/browser/themes/windows/menu-back-XP.png Binary files differdeleted file mode 100644 index ecb8ccd1a4..0000000000 --- a/browser/themes/windows/menu-back-XP.png +++ /dev/null diff --git a/browser/themes/windows/menu-forward-XP.png b/browser/themes/windows/menu-forward-XP.png Binary files differdeleted file mode 100644 index a7460dc27d..0000000000 --- a/browser/themes/windows/menu-forward-XP.png +++ /dev/null diff --git a/browser/themes/windows/pageInfo-XP.png b/browser/themes/windows/pageInfo-XP.png Binary files differdeleted file mode 100644 index bbf2572379..0000000000 --- a/browser/themes/windows/pageInfo-XP.png +++ /dev/null diff --git a/browser/themes/windows/places/allBookmarks-XP.png b/browser/themes/windows/places/allBookmarks-XP.png Binary files differdeleted file mode 100644 index f7903cc5f0..0000000000 --- a/browser/themes/windows/places/allBookmarks-XP.png +++ /dev/null diff --git a/browser/themes/windows/places/autocomplete-star-XPVista7.png b/browser/themes/windows/places/autocomplete-star-win7.png Binary files differindex af694e91c3..af694e91c3 100644 --- a/browser/themes/windows/places/autocomplete-star-XPVista7.png +++ b/browser/themes/windows/places/autocomplete-star-win7.png diff --git a/browser/themes/windows/places/bookmarksMenu-XP.png b/browser/themes/windows/places/bookmarksMenu-XP.png Binary files differdeleted file mode 100644 index 8f0c8bf583..0000000000 --- a/browser/themes/windows/places/bookmarksMenu-XP.png +++ /dev/null diff --git a/browser/themes/windows/places/bookmarksToolbar-XP.png b/browser/themes/windows/places/bookmarksToolbar-XP.png Binary files differdeleted file mode 100644 index 9e988de201..0000000000 --- a/browser/themes/windows/places/bookmarksToolbar-XP.png +++ /dev/null diff --git a/browser/themes/windows/places/bookmarksToolbar-menuPanel-XP.png b/browser/themes/windows/places/bookmarksToolbar-menuPanel-XP.png Binary files differdeleted file mode 100644 index 0e4247adb5..0000000000 --- a/browser/themes/windows/places/bookmarksToolbar-menuPanel-XP.png +++ /dev/null diff --git a/browser/themes/windows/places/calendar-XP.png b/browser/themes/windows/places/calendar-XP.png Binary files differdeleted file mode 100644 index 7645af5cd1..0000000000 --- a/browser/themes/windows/places/calendar-XP.png +++ /dev/null diff --git a/browser/themes/windows/places/history-XP.png b/browser/themes/windows/places/history-XP.png Binary files differdeleted file mode 100644 index fcc89bbbf0..0000000000 --- a/browser/themes/windows/places/history-XP.png +++ /dev/null diff --git a/browser/themes/windows/places/libraryToolbar-XP.png b/browser/themes/windows/places/libraryToolbar-XP.png Binary files differdeleted file mode 100644 index 75b390ff66..0000000000 --- a/browser/themes/windows/places/libraryToolbar-XP.png +++ /dev/null diff --git a/browser/themes/windows/places/organizer.css b/browser/themes/windows/places/organizer.css index 4de603b9f3..9ae4c83704 100644 --- a/browser/themes/windows/places/organizer.css +++ b/browser/themes/windows/places/organizer.css @@ -20,13 +20,6 @@ list-style-image: url("chrome://browser/skin/Toolbar.png"); } -@media (-moz-windows-theme: luna-silver) { - #back-button, - #forward-button { - list-style-image: url("chrome://browser/skin/Toolbar-lunaSilver.png"); - } -} - #back-button { -moz-image-region: rect(0, 54px, 18px, 36px); } @@ -119,11 +112,6 @@ -moz-image-region: rect(16px, 48px, 32px, 32px); } -/* Root View */ -#placesView { - border-top: 1px solid ThreeDDarkShadow; -} - /* Info box */ #detailsDeck { border-top: 1px solid ThreeDShadow; @@ -151,35 +139,28 @@ padding-inline-end: 9px; } - -@media not all and (-moz-os-version: windows-xp) { - #placesView { - border-top: none; +@media not all and (-moz-windows-classic) { + #placesToolbox { + -moz-appearance: none; + background-color: transparent; } - @media not all and (-moz-windows-classic) { - #placesToolbox { - -moz-appearance: none; - background-color: transparent; - } - - #placesToolbar { - -moz-appearance: none; - background-color: -moz-Dialog; - color: -moz-dialogText; - } + #placesToolbar { + -moz-appearance: none; + background-color: -moz-Dialog; + color: -moz-dialogText; } +} - @media (-moz-windows-default-theme) { - #placesView > splitter { - border: 0; - border-inline-end: 1px solid #A9B7C9; - min-width: 0; - width: 3px; - background-color: transparent; - margin-inline-start: -3px; - position: relative; - } +@media (-moz-windows-default-theme) { + #placesView > splitter { + border: 0; + border-inline-end: 1px solid #A9B7C9; + min-width: 0; + width: 3px; + background-color: transparent; + margin-inline-start: -3px; + position: relative; } } @@ -193,8 +174,7 @@ } } -@media (-moz-windows-default-theme) and (-moz-os-version: windows-vista), - (-moz-windows-default-theme) and (-moz-os-version: windows-win7) { +@media (-moz-windows-default-theme) and (-moz-os-version: windows-win7) { #placesView, #infoPane, #placesList, diff --git a/browser/themes/windows/places/places.css b/browser/themes/windows/places/places.css index 4ec8f6555b..769cfcc25d 100644 --- a/browser/themes/windows/places/places.css +++ b/browser/themes/windows/places/places.css @@ -24,21 +24,17 @@ cursor: default; } -/* Style Places sidebars as Vista media collection */ @media (-moz-windows-default-theme) { - @media not all and (-moz-os-version: windows-xp) { - .sidebar-placesTree { - background-color: transparent; - border-top: none; - } + .sidebar-placesTree { + background-color: transparent; + border-top: none; + } - .sidebar-placesTreechildren::-moz-tree-cell-text(leaf, hover) { - text-decoration: none; - } + .sidebar-placesTreechildren::-moz-tree-cell-text(leaf, hover) { + text-decoration: none; } - @media (-moz-os-version: windows-vista), - (-moz-os-version: windows-win7) { + @media (-moz-os-version: windows-win7) { #bookmarksPanel, #history-panel, #tabs-panel { diff --git a/browser/themes/windows/places/query-XP.png b/browser/themes/windows/places/query-XP.png Binary files differdeleted file mode 100644 index 9e79fc7915..0000000000 --- a/browser/themes/windows/places/query-XP.png +++ /dev/null diff --git a/browser/themes/windows/places/starred48-XP.png b/browser/themes/windows/places/starred48-XP.png Binary files differdeleted file mode 100644 index 1cb7bc57d3..0000000000 --- a/browser/themes/windows/places/starred48-XP.png +++ /dev/null diff --git a/browser/themes/windows/places/tag-XP.png b/browser/themes/windows/places/tag-XP.png Binary files differdeleted file mode 100644 index 4b4a13e662..0000000000 --- a/browser/themes/windows/places/tag-XP.png +++ /dev/null diff --git a/browser/themes/windows/places/toolbarDropMarker-XP.png b/browser/themes/windows/places/toolbarDropMarker-XP.png Binary files differdeleted file mode 100644 index 9173b7a7a3..0000000000 --- a/browser/themes/windows/places/toolbarDropMarker-XP.png +++ /dev/null diff --git a/browser/themes/windows/places/unsortedBookmarks-XP.png b/browser/themes/windows/places/unsortedBookmarks-XP.png Binary files differdeleted file mode 100644 index cf73f94649..0000000000 --- a/browser/themes/windows/places/unsortedBookmarks-XP.png +++ /dev/null diff --git a/browser/themes/windows/preferences/alwaysAsk-XP.png b/browser/themes/windows/preferences/alwaysAsk-XP.png Binary files differdeleted file mode 100644 index 8693211ac1..0000000000 --- a/browser/themes/windows/preferences/alwaysAsk-XP.png +++ /dev/null diff --git a/browser/themes/windows/preferences/application-XP.png b/browser/themes/windows/preferences/application-XP.png Binary files differdeleted file mode 100644 index 7d279ff849..0000000000 --- a/browser/themes/windows/preferences/application-XP.png +++ /dev/null diff --git a/browser/themes/windows/preferences/saveFile-XP.png b/browser/themes/windows/preferences/saveFile-XP.png Binary files differdeleted file mode 100644 index e115eaa9fd..0000000000 --- a/browser/themes/windows/preferences/saveFile-XP.png +++ /dev/null diff --git a/browser/themes/windows/privatebrowsing-mask-tabstrip-XPVista7.png b/browser/themes/windows/privatebrowsing-mask-tabstrip-win7.png Binary files differindex bd5d46a76a..bd5d46a76a 100644 --- a/browser/themes/windows/privatebrowsing-mask-tabstrip-XPVista7.png +++ b/browser/themes/windows/privatebrowsing-mask-tabstrip-win7.png diff --git a/browser/themes/windows/privatebrowsing-mask-titlebar-XPVista7-tall.png b/browser/themes/windows/privatebrowsing-mask-titlebar-win7-tall.png Binary files differindex 4a723c54e2..4a723c54e2 100644 --- a/browser/themes/windows/privatebrowsing-mask-titlebar-XPVista7-tall.png +++ b/browser/themes/windows/privatebrowsing-mask-titlebar-win7-tall.png diff --git a/browser/themes/windows/privatebrowsing-mask-titlebar-XPVista7.png b/browser/themes/windows/privatebrowsing-mask-titlebar-win7.png Binary files differindex 835912b534..835912b534 100644 --- a/browser/themes/windows/privatebrowsing-mask-titlebar-XPVista7.png +++ b/browser/themes/windows/privatebrowsing-mask-titlebar-win7.png diff --git a/browser/themes/windows/reload-stop-go-XPVista7.png b/browser/themes/windows/reload-stop-go-win7.png Binary files differindex 3ef32c3ce6..3ef32c3ce6 100644 --- a/browser/themes/windows/reload-stop-go-XPVista7.png +++ b/browser/themes/windows/reload-stop-go-win7.png diff --git a/browser/themes/windows/reload-stop-go-XPVista7@2x.png b/browser/themes/windows/reload-stop-go-win7@2x.png Binary files differindex 38b27bf0cd..38b27bf0cd 100644 --- a/browser/themes/windows/reload-stop-go-XPVista7@2x.png +++ b/browser/themes/windows/reload-stop-go-win7@2x.png diff --git a/browser/themes/windows/sync-horizontalbar-XPVista7.png b/browser/themes/windows/sync-horizontalbar-win7.png Binary files differindex 2c97ce6dbd..2c97ce6dbd 100644 --- a/browser/themes/windows/sync-horizontalbar-XPVista7.png +++ b/browser/themes/windows/sync-horizontalbar-win7.png diff --git a/browser/themes/windows/sync-horizontalbar-XPVista7@2x.png b/browser/themes/windows/sync-horizontalbar-win7@2x.png Binary files differindex ee117ab73c..ee117ab73c 100644 --- a/browser/themes/windows/sync-horizontalbar-XPVista7@2x.png +++ b/browser/themes/windows/sync-horizontalbar-win7@2x.png diff --git a/browser/themes/windows/syncProgress-horizontalbar-XPVista7.png b/browser/themes/windows/syncProgress-horizontalbar-win7.png Binary files differindex 48cd110559..48cd110559 100644 --- a/browser/themes/windows/syncProgress-horizontalbar-XPVista7.png +++ b/browser/themes/windows/syncProgress-horizontalbar-win7.png diff --git a/browser/themes/windows/syncProgress-horizontalbar-XPVista7@2x.png b/browser/themes/windows/syncProgress-horizontalbar-win7@2x.png Binary files differindex 741dd2ed44..741dd2ed44 100644 --- a/browser/themes/windows/syncProgress-horizontalbar-XPVista7@2x.png +++ b/browser/themes/windows/syncProgress-horizontalbar-win7@2x.png diff --git a/browser/themes/windows/syncProgress-toolbar-XPVista7.png b/browser/themes/windows/syncProgress-toolbar-win7.png Binary files differindex 49e224f0d9..49e224f0d9 100644 --- a/browser/themes/windows/syncProgress-toolbar-XPVista7.png +++ b/browser/themes/windows/syncProgress-toolbar-win7.png diff --git a/browser/themes/windows/syncProgress-toolbar-XPVista7@2x.png b/browser/themes/windows/syncProgress-toolbar-win7@2x.png Binary files differindex fd20387256..fd20387256 100644 --- a/browser/themes/windows/syncProgress-toolbar-XPVista7@2x.png +++ b/browser/themes/windows/syncProgress-toolbar-win7@2x.png diff --git a/browser/themes/windows/tabbrowser/newtab-inverted-XPVista7.svg b/browser/themes/windows/tabbrowser/newtab-inverted-win7.svg index 10ffbc7451..10ffbc7451 100644 --- a/browser/themes/windows/tabbrowser/newtab-inverted-XPVista7.svg +++ b/browser/themes/windows/tabbrowser/newtab-inverted-win7.svg diff --git a/browser/themes/windows/tabbrowser/newtab-XPVista7.svg b/browser/themes/windows/tabbrowser/newtab-win7.svg index 3f431c9db9..3f431c9db9 100644 --- a/browser/themes/windows/tabbrowser/newtab-XPVista7.svg +++ b/browser/themes/windows/tabbrowser/newtab-win7.svg diff --git a/browser/themes/windows/tabbrowser/tab-arrow-left-XPVista7.svg b/browser/themes/windows/tabbrowser/tab-arrow-left-win7.svg index 41bb5ab131..41bb5ab131 100644 --- a/browser/themes/windows/tabbrowser/tab-arrow-left-XPVista7.svg +++ b/browser/themes/windows/tabbrowser/tab-arrow-left-win7.svg diff --git a/browser/themes/windows/toolbarbutton-dropdown-arrow-XPVista7.png b/browser/themes/windows/toolbarbutton-dropdown-arrow-win7.png Binary files differindex 5f892f532e..5f892f532e 100644 --- a/browser/themes/windows/toolbarbutton-dropdown-arrow-XPVista7.png +++ b/browser/themes/windows/toolbarbutton-dropdown-arrow-win7.png diff --git a/browser/themes/windows/urlbar-history-dropmarker-XPVista7.png b/browser/themes/windows/urlbar-history-dropmarker-win7.png Binary files differindex b03338822c..b03338822c 100644 --- a/browser/themes/windows/urlbar-history-dropmarker-XPVista7.png +++ b/browser/themes/windows/urlbar-history-dropmarker-win7.png diff --git a/browser/themes/windows/urlbar-history-dropmarker-XPVista7@2x.png b/browser/themes/windows/urlbar-history-dropmarker-win7@2x.png Binary files differindex bff2997f85..bff2997f85 100644 --- a/browser/themes/windows/urlbar-history-dropmarker-XPVista7@2x.png +++ b/browser/themes/windows/urlbar-history-dropmarker-win7@2x.png diff --git a/browser/themes/windows/windowsShared.inc b/browser/themes/windows/windowsShared.inc index 0cb2ab1632..199a622920 100644 --- a/browser/themes/windows/windowsShared.inc +++ b/browser/themes/windows/windowsShared.inc @@ -8,6 +8,4 @@ %define fgTabTexture linear-gradient(transparent 2px, @toolbarHighlight@ 2px, @toolbarHighlight@) %define fgTabBackgroundColor -moz-dialog %define fgTabTextureLWT @fgTabTexture@ - -% Aero-only defines %define customToolbarColor hsl(210,75%,92%) diff --git a/config/milestone.txt b/config/milestone.txt index 48a995e3cc..05d41f9342 100644 --- a/config/milestone.txt +++ b/config/milestone.txt @@ -10,4 +10,4 @@ # hardcoded milestones in the tree from these two files. #-------------------------------------------------------- -52.6.0 +4.1.0 diff --git a/devtools/client/scratchpad/scratchpad.xul b/devtools/client/scratchpad/scratchpad.xul index 0603fa95e7..3712f163d2 100644 --- a/devtools/client/scratchpad/scratchpad.xul +++ b/devtools/client/scratchpad/scratchpad.xul @@ -121,7 +121,7 @@ <key id="sp-key-reloadAndRun" key="&reloadAndRun.key;" command="sp-cmd-reloadAndRun" - modifiers="accel,shift"/> + modifiers="accel,alt"/> <key id="sp-key-evalFunction" key="&evalFunction.key;" command="sp-cmd-evalFunction" diff --git a/docshell/base/nsAboutRedirector.cpp b/docshell/base/nsAboutRedirector.cpp index cb62eacbb6..e7d3628645 100644 --- a/docshell/base/nsAboutRedirector.cpp +++ b/docshell/base/nsAboutRedirector.cpp @@ -54,8 +54,9 @@ static RedirEntry kRedirMap[] = { { "crashes", "chrome://global/content/crashes.xhtml", 0 }, #endif { - "credits", "https://www.mozilla.org/credits/", - nsIAboutModule::URI_SAFE_FOR_UNTRUSTED_CONTENT + "credits", "http://www.palemoon.org/Contributors.shtml", + nsIAboutModule::URI_SAFE_FOR_UNTRUSTED_CONTENT | + nsIAboutModule::MAKE_LINKABLE }, #ifdef MOZ_DEVTOOLS { diff --git a/docshell/base/nsDSURIContentListener.cpp b/docshell/base/nsDSURIContentListener.cpp index cfac54f7f4..93ce3cb264 100644 --- a/docshell/base/nsDSURIContentListener.cpp +++ b/docshell/base/nsDSURIContentListener.cpp @@ -22,6 +22,7 @@ #include "nsIScriptError.h" #include "nsDocShellLoadTypes.h" #include "nsIMultiPartChannel.h" +#include "mozilla/dom/nsCSPUtils.h" using namespace mozilla; @@ -84,14 +85,6 @@ nsDSURIContentListener::DoContent(const nsACString& aContentType, NS_ENSURE_ARG_POINTER(aContentHandler); NS_ENSURE_TRUE(mDocShell, NS_ERROR_FAILURE); - // Check whether X-Frame-Options permits us to load this content in an - // iframe and abort the load (unless we've disabled x-frame-options - // checking). - if (!CheckFrameOptions(aRequest)) { - *aAbortProcess = true; - return NS_OK; - } - *aAbortProcess = false; // determine if the channel has just been retargeted to us... @@ -265,9 +258,10 @@ nsDSURIContentListener::SetParentContentListener( return NS_OK; } -bool +/* static */ bool nsDSURIContentListener::CheckOneFrameOptionsPolicy(nsIHttpChannel* aHttpChannel, - const nsAString& aPolicy) + const nsAString& aPolicy, + nsIDocShell* aDocShell) { static const char allowFrom[] = "allow-from"; const uint32_t allowFromLen = ArrayLength(allowFrom) - 1; @@ -285,7 +279,7 @@ nsDSURIContentListener::CheckOneFrameOptionsPolicy(nsIHttpChannel* aHttpChannel, aHttpChannel->GetURI(getter_AddRefs(uri)); // XXXkhuey when does this happen? Is returning true safe here? - if (!mDocShell) { + if (!aDocShell) { return true; } @@ -293,7 +287,7 @@ nsDSURIContentListener::CheckOneFrameOptionsPolicy(nsIHttpChannel* aHttpChannel, // window, if we're not the top. X-F-O: SAMEORIGIN requires that the // document must be same-origin with top window. X-F-O: DENY requires that // the document must never be framed. - nsCOMPtr<nsPIDOMWindowOuter> thisWindow = mDocShell->GetWindow(); + nsCOMPtr<nsPIDOMWindowOuter> thisWindow = aDocShell->GetWindow(); // If we don't have DOMWindow there is no risk of clickjacking if (!thisWindow) { return true; @@ -313,7 +307,7 @@ nsDSURIContentListener::CheckOneFrameOptionsPolicy(nsIHttpChannel* aHttpChannel, // content-type docshell doesn't work because some chrome documents are // loaded in content docshells (see bug 593387). nsCOMPtr<nsIDocShellTreeItem> thisDocShellItem( - do_QueryInterface(static_cast<nsIDocShell*>(mDocShell))); + do_QueryInterface(static_cast<nsIDocShell*>(aDocShell))); nsCOMPtr<nsIDocShellTreeItem> parentDocShellItem; nsCOMPtr<nsIDocShellTreeItem> curDocShellItem = thisDocShellItem; nsCOMPtr<nsIDocument> topDoc; @@ -402,22 +396,66 @@ nsDSURIContentListener::CheckOneFrameOptionsPolicy(nsIHttpChannel* aHttpChannel, return true; } +// Ignore x-frame-options if CSP with frame-ancestors exists +static bool +ShouldIgnoreFrameOptions(nsIChannel* aChannel, nsIPrincipal* aPrincipal) +{ + NS_ENSURE_TRUE(aChannel, false); + NS_ENSURE_TRUE(aPrincipal, false); + + nsCOMPtr<nsIContentSecurityPolicy> csp; + aPrincipal->GetCsp(getter_AddRefs(csp)); + if (!csp) { + // if there is no CSP, then there is nothing to do here + return false; + } + + bool enforcesFrameAncestors = false; + csp->GetEnforcesFrameAncestors(&enforcesFrameAncestors); + if (!enforcesFrameAncestors) { + // if CSP does not contain frame-ancestors, then there + // is nothing to do here. + return false; + } + + // log warning to console that xfo is ignored because of CSP + nsCOMPtr<nsILoadInfo> loadInfo = aChannel->GetLoadInfo(); + uint64_t innerWindowID = loadInfo ? loadInfo->GetInnerWindowID() : 0; + const char16_t* params[] = { u"x-frame-options", + u"frame-ancestors" }; + CSP_LogLocalizedStr(u"IgnoringSrcBecauseOfDirective", + params, ArrayLength(params), + EmptyString(), // no sourcefile + EmptyString(), // no scriptsample + 0, // no linenumber + 0, // no columnnumber + nsIScriptError::warningFlag, + "CSP", innerWindowID); + + return true; +} + // Check if X-Frame-Options permits this document to be loaded as a subdocument. // This will iterate through and check any number of X-Frame-Options policies // in the request (comma-separated in a header, multiple headers, etc). -bool -nsDSURIContentListener::CheckFrameOptions(nsIRequest* aRequest) +/* static */ bool +nsDSURIContentListener::CheckFrameOptions(nsIChannel* aChannel, + nsIDocShell* aDocShell, + nsIPrincipal* aPrincipal) { - nsresult rv; - nsCOMPtr<nsIChannel> chan = do_QueryInterface(aRequest); - if (!chan) { + if (!aChannel || !aDocShell) { return true; } - nsCOMPtr<nsIHttpChannel> httpChannel = do_QueryInterface(chan); + if (ShouldIgnoreFrameOptions(aChannel, aPrincipal)) { + return true; + } + + nsresult rv; + nsCOMPtr<nsIHttpChannel> httpChannel = do_QueryInterface(aChannel); if (!httpChannel) { // check if it is hiding in a multipart channel - rv = mDocShell->GetHttpChannel(chan, getter_AddRefs(httpChannel)); + rv = nsDocShell::Cast(aDocShell)->GetHttpChannel(aChannel, getter_AddRefs(httpChannel)); if (NS_FAILED(rv)) { return false; } @@ -442,11 +480,11 @@ nsDSURIContentListener::CheckFrameOptions(nsIRequest* aRequest) nsCharSeparatedTokenizer tokenizer(xfoHeaderValue, ','); while (tokenizer.hasMoreTokens()) { const nsSubstring& tok = tokenizer.nextToken(); - if (!CheckOneFrameOptionsPolicy(httpChannel, tok)) { + if (!CheckOneFrameOptionsPolicy(httpChannel, tok, aDocShell)) { // cancel the load and display about:blank httpChannel->Cancel(NS_BINDING_ABORTED); - if (mDocShell) { - nsCOMPtr<nsIWebNavigation> webNav(do_QueryObject(mDocShell)); + if (aDocShell) { + nsCOMPtr<nsIWebNavigation> webNav(do_QueryObject(aDocShell)); if (webNav) { webNav->LoadURI(u"about:blank", 0, nullptr, nullptr, nullptr); @@ -459,7 +497,7 @@ nsDSURIContentListener::CheckFrameOptions(nsIRequest* aRequest) return true; } -void +/* static */ void nsDSURIContentListener::ReportXFOViolation(nsIDocShellTreeItem* aTopDocShellItem, nsIURI* aThisURI, XFOHeader aHeader) diff --git a/docshell/base/nsDSURIContentListener.h b/docshell/base/nsDSURIContentListener.h index f33d1c045e..4328134710 100644 --- a/docshell/base/nsDSURIContentListener.h +++ b/docshell/base/nsDSURIContentListener.h @@ -28,6 +28,12 @@ public: nsresult Init(); + // Determine if X-Frame-Options allows content to be framed + // as a subdocument + static bool CheckFrameOptions(nsIChannel* aChannel, + nsIDocShell* aDocShell, + nsIPrincipal* aPrincipal); + protected: explicit nsDSURIContentListener(nsDocShell* aDocShell); virtual ~nsDSURIContentListener(); @@ -39,12 +45,9 @@ protected: mExistingJPEGStreamListener = nullptr; } - // Determine if X-Frame-Options allows content to be framed - // as a subdocument - bool CheckFrameOptions(nsIRequest* aRequest); - bool CheckOneFrameOptionsPolicy(nsIHttpChannel* aHttpChannel, - const nsAString& aPolicy); - + static bool CheckOneFrameOptionsPolicy(nsIHttpChannel* aHttpChannel, + const nsAString& aPolicy, + nsIDocShell* aDocShell); enum XFOHeader { eDENY, @@ -52,9 +55,9 @@ protected: eALLOWFROM }; - void ReportXFOViolation(nsIDocShellTreeItem* aTopDocShellItem, - nsIURI* aThisURI, - XFOHeader aHeader); + static void ReportXFOViolation(nsIDocShellTreeItem* aTopDocShellItem, + nsIURI* aThisURI, + XFOHeader aHeader); protected: nsDocShell* mDocShell; diff --git a/docshell/base/nsDocShell.cpp b/docshell/base/nsDocShell.cpp index ab119a016a..2e08e67207 100644 --- a/docshell/base/nsDocShell.cpp +++ b/docshell/base/nsDocShell.cpp @@ -11025,6 +11025,29 @@ nsDocShell::DoURILoad(nsIURI* aURI, } } + // Navigational requests that are same origin need to be upgraded in case + // upgrade-insecure-requests is present. Please note that in that case + // the triggeringPrincipal is holding the CSP that potentially + // holds upgrade-insecure-requests. + nsCOMPtr<nsIContentSecurityPolicy> csp; + aTriggeringPrincipal->GetCsp(getter_AddRefs(csp)); + if (csp) { + bool upgradeInsecureRequests = false; + csp->GetUpgradeInsecureRequests(&upgradeInsecureRequests); + if (upgradeInsecureRequests) { + // only upgrade if the navigation is same origin + nsCOMPtr<nsIPrincipal> resultPrincipal; + rv = nsContentUtils::GetSecurityManager()-> + GetChannelResultPrincipal(channel, + getter_AddRefs(resultPrincipal)); + NS_ENSURE_SUCCESS(rv, rv); + if (resultPrincipal->Equals(aTriggeringPrincipal)) { + static_cast<mozilla::LoadInfo*>(loadInfo.get())->SetUpgradeInsecureRequests(); + } + } + } + + nsCOMPtr<nsIApplicationCacheChannel> appCacheChannel = do_QueryInterface(channel); if (appCacheChannel) { diff --git a/docshell/test/file_bug1151421.html b/docshell/test/file_bug1151421.html new file mode 100644 index 0000000000..7bb8c8f363 --- /dev/null +++ b/docshell/test/file_bug1151421.html @@ -0,0 +1,19 @@ +<html> +<head> +<style> +body, html { + height: 100%; +} +.spacer { + height: 80%; +} +</style> +</head> +<body onload='(parent || opener).childLoad()'> + +<div class="spacer"></div> +<div id="content">content</div> +<div class="spacer"></div> + +</body> +</html> diff --git a/docshell/test/mochitest.ini b/docshell/test/mochitest.ini index 725486b771..7b27908fb1 100644 --- a/docshell/test/mochitest.ini +++ b/docshell/test/mochitest.ini @@ -32,6 +32,7 @@ support-files = file_bug680257.html file_bug703855.html file_bug728939.html + file_bug1151421.html file_pushState_after_document_open.html historyframes.html @@ -85,6 +86,7 @@ support-files = file_bug668513.html [test_bug797909.html] [test_bug1045096.html] [test_bug1121701.html] +[test_bug1151421.html] [test_bug1186774.html] [test_forceinheritprincipal_overrule_owner.html] [test_framedhistoryframes.html] diff --git a/docshell/test/navigation/file_scrollRestoration.html b/docshell/test/navigation/file_scrollRestoration.html index 5450c27246..92e43d7fbb 100644 --- a/docshell/test/navigation/file_scrollRestoration.html +++ b/docshell/test/navigation/file_scrollRestoration.html @@ -26,7 +26,7 @@ } case 2: { opener.is(event.persisted, false, "Shouldn't have persisted session history entry."); - opener.isnot(window.scrollY, 0, "Should have restored scrolling."); + opener.isnot(Math.round(window.scrollY), 0, "Should have restored scrolling."); opener.is(history.scrollRestoration, "auto", "Should have the same scrollRestoration as before reload."); history.scrollRestoration = "manual"; window.onunload = function() {} // Disable bfcache. @@ -45,7 +45,7 @@ } case 4: { opener.is(event.persisted, true, "Should have persisted session history entry."); - opener.isnot(window.scrollY, 0, "Should have kept the old scroll position."); + opener.isnot(Math.round(window.scrollY), 0, "Should have kept the old scroll position."); opener.is(history.scrollRestoration, "manual", "Should have the same scrollRestoration as before reload."); window.scrollTo(0, 0); window.location.hash = "hash"; @@ -53,7 +53,7 @@ break; } case 5: { - opener.isnot(window.scrollY, 0, "Should have scrolled to #hash."); + opener.isnot(Math.round(window.scrollY), 0, "Should have scrolled to #hash."); opener.is(history.scrollRestoration, "manual", "Should have the same scrollRestoration mode as before fragment navigation."); window.onunload = function() {} // Disable bfcache. opener.setTimeout("is(testWindow.history.scrollRestoration, 'auto'); testWindow.history.back();", 250); @@ -70,7 +70,7 @@ history.pushState({ state: "state2" }, "state2"); window.scrollTo(0, 0); history.back(); - opener.isnot(window.scrollY, 0, "Should have scrolled back to the state1's position"); + opener.isnot(Math.round(window.scrollY), 0, "Should have scrolled back to the state1's position"); opener.is(history.state.state, "state1", "Unexpected state."); history.scrollRestoration = "manual"; @@ -79,17 +79,17 @@ history.pushState({ state: "state4" }, "state4"); window.scrollTo(0, 0); history.back(); - opener.is(window.scrollY, 0, "Shouldn't have scrolled back to the state3's position"); + opener.is(Math.round(window.scrollY), 0, "Shouldn't have scrolled back to the state3's position"); opener.is(history.state.state, "state3", "Unexpected state."); history.pushState({ state: "state5" }, "state5"); history.scrollRestoration = "auto"; document.getElementById("bottom").scrollIntoView(); - opener.isnot(window.scrollY, 0, "Should have scrolled to 'bottom'."); + opener.isnot(Math.round(window.scrollY), 0, "Should have scrolled to 'bottom'."); history.back(); window.scrollTo(0, 0); history.forward(); - opener.isnot(window.scrollY, 0, "Should have scrolled back to the state5's position"); + opener.isnot(Math.round(window.scrollY), 0, "Should have scrolled back to the state5's position"); var ifr = document.createElement("iframe"); ifr.src = "data:text/html,"; diff --git a/docshell/test/test_bug1151421.html b/docshell/test/test_bug1151421.html new file mode 100644 index 0000000000..76e34d502d --- /dev/null +++ b/docshell/test/test_bug1151421.html @@ -0,0 +1,61 @@ +<!DOCTYPE HTML> +<html> +<!-- +https://bugzilla.mozilla.org/show_bug.cgi?id=1151421 +--> +<head> + <title>Test for Bug 1151421</title> + <script type="application/javascript" src="/tests/SimpleTest/SimpleTest.js"></script> + <link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css"/> +</head> +<body> +<a target="_blank" href="https://bugzilla.mozilla.org/show_bug.cgi?id=1151421">Mozilla Bug 1151421</a> + +<script type="application/javascript"> + +/** Test for Bug 1151421 **/ +SimpleTest.waitForExplicitFinish(); + +function childLoad() { + // Spin the event loop so we leave the onload handler. + SimpleTest.executeSoon(childLoad2); +} + +function childLoad2() { + let cw = iframe.contentWindow; + let content = cw.document.getElementById("content"); + + // Create a function to calculate an invariant. + let topPlusOffset = function() + { + return Math.round(content.getBoundingClientRect().top + cw.pageYOffset); + } + + let initialTPO = topPlusOffset(); + + // Scroll the iframe to various positions, and check the TPO. + // Scrolling down to the bottom will adjust the page offset by a fractional amount. + let positions = [-100, 0.17, 0, 1.5, 10.41, 1e6, 12.1]; + + // Run some tests with scrollTo() and ensure we have the same invariant after scrolling. + positions.forEach(function(pos) { + cw.scrollTo(0, pos); + is(topPlusOffset(), initialTPO, "Top plus offset should remain invariant across scrolling."); + }); + + positions.reverse().forEach(function(pos) { + cw.scrollTo(0, pos); + is(topPlusOffset(), initialTPO, "(reverse) Top plus offset should remain invariant across scrolling."); + }); + + SimpleTest.finish(); +} + +</script> + +<!-- When the iframe loads, it calls childLoad(). --> +<br> +<iframe height='100px' id='iframe' src='file_bug1151421.html'></iframe> + +</body> +</html> diff --git a/docshell/test/test_bug1186774.html b/docshell/test/test_bug1186774.html index 52ef5f62cb..623e7996b7 100644 --- a/docshell/test/test_bug1186774.html +++ b/docshell/test/test_bug1186774.html @@ -28,7 +28,7 @@ function runTest() { } child.onpopstate = function() { - is(child.scrollY, 6000, "Shouldn't have scrolled before popstate"); + is(Math.round(child.scrollY), 6000, "Shouldn't have scrolled before popstate"); child.close(); SimpleTest.finish(); } diff --git a/docshell/test/test_bug590573.html b/docshell/test/test_bug590573.html index aa6d3bd79f..e218140ea6 100644 --- a/docshell/test/test_bug590573.html +++ b/docshell/test/test_bug590573.html @@ -147,21 +147,21 @@ function* testBody() popup.scroll(0, 100); popup.history.pushState('', '', '?pushed'); - is(popup.scrollY, 100, "test 2"); + is(Math.round(popup.scrollY), 100, "test 2"); popup.scroll(0, 200); // set state-2's position to 200 popup.history.back(); - is(popup.scrollY, 100, "test 3"); + is(Math.round(popup.scrollY), 100, "test 3"); popup.scroll(0, 150); // set original page's position to 150 popup.history.forward(); - is(popup.scrollY, 200, "test 4"); + is(Math.round(popup.scrollY), 200, "test 4"); popup.history.back(); - is(popup.scrollY, 150, "test 5"); + is(Math.round(popup.scrollY), 150, "test 5"); popup.history.forward(); - is(popup.scrollY, 200, "test 6"); + is(Math.round(popup.scrollY), 200, "test 6"); // At this point, the history looks like: // PATH POSITION @@ -202,13 +202,13 @@ function* testBody() is(popup.location.search, "?pushed"); ok(popup.document.getElementById('div1'), 'page should have div1.'); - is(popup.scrollY, 200, "test 8"); + is(Math.round(popup.scrollY), 200, "test 8"); popup.history.back(); - is(popup.scrollY, 150, "test 9"); + is(Math.round(popup.scrollY), 150, "test 9"); popup.history.forward(); - is(popup.scrollY, 200, "test 10"); + is(Math.round(popup.scrollY), 200, "test 10"); // Spin one last time... setTimeout(pageLoad, 0); diff --git a/docshell/test/test_bug653741.html b/docshell/test/test_bug653741.html index f4d4587b8c..a1faf5e2dd 100644 --- a/docshell/test/test_bug653741.html +++ b/docshell/test/test_bug653741.html @@ -27,7 +27,7 @@ function childLoad2() { // Save the Y offset. For sanity's sake, make sure it's not 0, because we // should be at the bottom of the page! - let origYOffset = cw.pageYOffset; + let origYOffset = Math.round(cw.pageYOffset); ok(origYOffset != 0, 'Original Y offset is not 0.'); // Scroll the iframe to the top, then navigate to #bottom again. @@ -37,7 +37,7 @@ function childLoad2() { // bottom again. cw.location = cw.location + ''; - is(cw.pageYOffset, origYOffset, 'Correct offset after reloading page.'); + is(Math.round(cw.pageYOffset), origYOffset, 'Correct offset after reloading page.'); SimpleTest.finish(); } diff --git a/docshell/test/test_bug662170.html b/docshell/test/test_bug662170.html index 514bb55b16..0e626fed48 100644 --- a/docshell/test/test_bug662170.html +++ b/docshell/test/test_bug662170.html @@ -32,7 +32,7 @@ function childLoad2() { cw.scrollTo(0, 300); // Did we actually scroll somewhere? - isnot(cw.pageYOffset, 0, 'Y offset should be non-zero after scrolling.'); + isnot(Math.round(cw.pageYOffset), 0, 'Y offset should be non-zero after scrolling.'); // Now load file_bug662170.html#, which should take us to the top of the // page. diff --git a/dom/base/Navigator.cpp b/dom/base/Navigator.cpp index 9db9065142..5c315517c1 100644 --- a/dom/base/Navigator.cpp +++ b/dom/base/Navigator.cpp @@ -1860,16 +1860,6 @@ Navigator::GetUserAgent(nsPIDOMWindowInner* aWindow, nsIURI* aURI, { MOZ_ASSERT(NS_IsMainThread()); - if (!aIsCallerChrome) { - const nsAdoptingString& override = - mozilla::Preferences::GetString("general.useragent.override"); - - if (override) { - aUserAgent = override; - return NS_OK; - } - } - nsresult rv; nsCOMPtr<nsIHttpProtocolHandler> service(do_GetService(NS_NETWORK_PROTOCOL_CONTRACTID_PREFIX "http", &rv)); diff --git a/dom/base/nsDocument.cpp b/dom/base/nsDocument.cpp index c6f58c57f5..eaea49b02b 100644 --- a/dom/base/nsDocument.cpp +++ b/dom/base/nsDocument.cpp @@ -61,6 +61,7 @@ #include "nsGenericHTMLElement.h" #include "mozilla/dom/CDATASection.h" #include "mozilla/dom/ProcessingInstruction.h" +#include "nsDSURIContentListener.h" #include "nsDOMString.h" #include "nsNodeUtils.h" #include "nsLayoutUtils.h" // for GetFrameForPoint @@ -2456,6 +2457,15 @@ nsDocument::StartDocumentLoad(const char* aCommand, nsIChannel* aChannel, NS_ENSURE_SUCCESS(rv, rv); } + // XFO needs to be checked after CSP because it is ignored if + // the CSP defines frame-ancestors. + if (!nsDSURIContentListener::CheckFrameOptions(aChannel, docShell, NodePrincipal())) { + MOZ_LOG(gCspPRLog, LogLevel::Debug, + ("XFO doesn't like frame's ancestry, not loading.")); + // stop! ERROR page! + aChannel->Cancel(NS_ERROR_CSP_FRAME_ANCESTOR_VIOLATION); + } + return NS_OK; } diff --git a/dom/base/nsDocument.h b/dom/base/nsDocument.h index 2482d30570..3725b3c18f 100644 --- a/dom/base/nsDocument.h +++ b/dom/base/nsDocument.h @@ -1493,7 +1493,6 @@ private: void PostUnblockOnloadEvent(); void DoUnblockOnload(); - nsresult CheckFrameOptions(); nsresult InitCSP(nsIChannel* aChannel); /** diff --git a/dom/base/nsGlobalWindow.cpp b/dom/base/nsGlobalWindow.cpp index 8ff4b84ce3..f784031f6a 100644 --- a/dom/base/nsGlobalWindow.cpp +++ b/dom/base/nsGlobalWindow.cpp @@ -6187,7 +6187,7 @@ nsGlobalWindow::GetScrollMaxY(ErrorResult& aError) FORWARD_TO_OUTER_OR_THROW(GetScrollBoundaryOuter, (eSideBottom), aError, 0); } -CSSIntPoint +CSSPoint nsGlobalWindow::GetScrollXY(bool aDoFlush) { MOZ_ASSERT(IsOuterWindow()); @@ -6211,30 +6211,30 @@ nsGlobalWindow::GetScrollXY(bool aDoFlush) return GetScrollXY(true); } - return sf->GetScrollPositionCSSPixels(); + return CSSPoint::FromAppUnits(scrollPos); } -int32_t +double nsGlobalWindow::GetScrollXOuter() { MOZ_RELEASE_ASSERT(IsOuterWindow()); return GetScrollXY(false).x; } -int32_t +double nsGlobalWindow::GetScrollX(ErrorResult& aError) { FORWARD_TO_OUTER_OR_THROW(GetScrollXOuter, (), aError, 0); } -int32_t +double nsGlobalWindow::GetScrollYOuter() { MOZ_RELEASE_ASSERT(IsOuterWindow()); return GetScrollXY(false).y; } -int32_t +double nsGlobalWindow::GetScrollY(ErrorResult& aError) { FORWARD_TO_OUTER_OR_THROW(GetScrollYOuter, (), aError, 0); diff --git a/dom/base/nsGlobalWindow.h b/dom/base/nsGlobalWindow.h index eab91c2e4f..dbceeab742 100644 --- a/dom/base/nsGlobalWindow.h +++ b/dom/base/nsGlobalWindow.h @@ -1050,15 +1050,15 @@ public: void SetInnerHeight(JSContext* aCx, JS::Handle<JS::Value> aValue, mozilla::dom::CallerType aCallerType, mozilla::ErrorResult& aError); - int32_t GetScrollXOuter(); - int32_t GetScrollX(mozilla::ErrorResult& aError); - int32_t GetPageXOffset(mozilla::ErrorResult& aError) + double GetScrollXOuter(); + double GetScrollX(mozilla::ErrorResult& aError); + double GetPageXOffset(mozilla::ErrorResult& aError) { return GetScrollX(aError); } - int32_t GetScrollYOuter(); - int32_t GetScrollY(mozilla::ErrorResult& aError); - int32_t GetPageYOffset(mozilla::ErrorResult& aError) + double GetScrollYOuter(); + double GetScrollY(mozilla::ErrorResult& aError); + double GetPageYOffset(mozilla::ErrorResult& aError) { return GetScrollY(aError); } @@ -1579,7 +1579,7 @@ public: // If aDoFlush is true, we'll flush our own layout; otherwise we'll try to // just flush our parent and only flush ourselves if we think we need to. // Outer windows only. - mozilla::CSSIntPoint GetScrollXY(bool aDoFlush); + mozilla::CSSPoint GetScrollXY(bool aDoFlush); int32_t GetScrollBoundaryOuter(mozilla::Side aSide); diff --git a/dom/base/nsPluginArray.cpp b/dom/base/nsPluginArray.cpp index b9c946ca36..5b9378ae08 100644 --- a/dom/base/nsPluginArray.cpp +++ b/dom/base/nsPluginArray.cpp @@ -372,9 +372,21 @@ nsPluginArray::EnsurePlugins() nsCString permString; nsresult rv = pluginHost->GetPermissionStringForTag(pluginTag, 0, permString); if (rv == NS_OK) { - nsIPrincipal* principal = mWindow->GetExtantDoc()->NodePrincipal(); - nsCOMPtr<nsIPermissionManager> permMgr = services::GetPermissionManager(); - permMgr->TestPermissionFromPrincipal(principal, permString.get(), &permission); + nsCOMPtr<nsIDocument> currentDoc = mWindow->GetExtantDoc(); + + // The top-level content document gets the final say on whether or not + // a plugin is going to be hidden or not, regardless of the origin + // that a subframe is hosted at. This is to avoid spamming the user + // with the hidden plugin notification bar when third-party iframes + // attempt to access navigator.plugins after the user has already + // expressed that the top-level document has this permission. + nsCOMPtr<nsIDocument> topDoc = currentDoc->GetTopLevelContentDocument(); + + if (topDoc) { + nsIPrincipal* principal = topDoc->NodePrincipal(); + nsCOMPtr<nsIPermissionManager> permMgr = services::GetPermissionManager(); + permMgr->TestPermissionFromPrincipal(principal, permString.get(), &permission); + } } } } diff --git a/dom/base/test/test_viewport_scroll.html b/dom/base/test/test_viewport_scroll.html index 9b812360b2..7db02b7815 100644 --- a/dom/base/test/test_viewport_scroll.html +++ b/dom/base/test/test_viewport_scroll.html @@ -28,10 +28,10 @@ function subtest(winProp, elemProp, win, correctElement, elemToSet, otherElem1, win.scrollTo(50, 50); elemToSet[elemProp] = 100; if (elemToSet == correctElement) { - is(win[winProp], 100, "Setting " + elemToSet.name + "." + elemProp + " should scroll"); + is(Math.round(win[winProp]), 100, "Setting " + elemToSet.name + "." + elemProp + " should scroll"); is(elemToSet[elemProp], 100, "Reading back " + elemToSet.name + "." + elemProp + " after scrolling"); } else { - is(win[winProp], 50, "Setting " + elemToSet.name + "." + elemProp + " should not scroll"); + is(Math.round(win[winProp]), 50, "Setting " + elemToSet.name + "." + elemProp + " should not scroll"); is(elemToSet[elemProp], 0, "Reading back " + elemToSet.name + "." + elemProp + " after not scrolling"); } if (otherElem1 == correctElement) { diff --git a/dom/browser-element/mochitest/browserElement_ScrollEvent.js b/dom/browser-element/mochitest/browserElement_ScrollEvent.js index 5c4b4dcf97..06dc91b862 100644 --- a/dom/browser-element/mochitest/browserElement_ScrollEvent.js +++ b/dom/browser-element/mochitest/browserElement_ScrollEvent.js @@ -16,8 +16,8 @@ function runTest() { iframe.addEventListener("mozbrowserscroll", function(e) { ok(true, "got mozbrowserscroll event."); ok(e.detail, "event.detail is not null."); - ok(e.detail.top === 4000, "top position is correct."); - ok(e.detail.left === 4000, "left position is correct."); + ok(Math.round(e.detail.top) == 4000, "top position is correct."); + ok(Math.round(e.detail.left) == 4000, "left position is correct."); SimpleTest.finish(); }); diff --git a/dom/interfaces/security/nsIContentSecurityPolicy.idl b/dom/interfaces/security/nsIContentSecurityPolicy.idl index ade5b12439..51ca46f2a8 100644 --- a/dom/interfaces/security/nsIContentSecurityPolicy.idl +++ b/dom/interfaces/security/nsIContentSecurityPolicy.idl @@ -98,6 +98,11 @@ interface nsIContentSecurityPolicy : nsISerializable readonly attribute bool blockAllMixedContent; /** + * Returns whether this policy enforces the frame-ancestors directive. + */ + readonly attribute bool enforcesFrameAncestors; + + /** * Obtains the referrer policy (as integer) for this browsing context as * specified in CSP. If there are multiple policies and... * - only one sets a referrer policy: that policy is returned diff --git a/dom/locales/en-US/chrome/security/csp.properties b/dom/locales/en-US/chrome/security/csp.properties index fc7fc04ba2..4124ef8aac 100644 --- a/dom/locales/en-US/chrome/security/csp.properties +++ b/dom/locales/en-US/chrome/security/csp.properties @@ -91,6 +91,10 @@ ignoringReportOnlyDirective = Ignoring sandbox directive when delivered in a rep # LOCALIZATION NOTE (deprecatedReferrerDirective): # %1$S is the value of the deprecated Referrer Directive. deprecatedReferrerDirective = Referrer Directive ‘%1$S’ has been deprecated. Please use the Referrer-Policy header instead. +# LOCALIZATION NOTE (IgnoringSrcBecauseOfDirective): +# %1$S is the name of the src that is ignored. +# %2$S is the name of the directive that causes the src to be ignored. +IgnoringSrcBecauseOfDirective=Ignoring ‘%1$S’ because of ‘%2$S’ directive. # CSP Errors: # LOCALIZATION NOTE (couldntParseInvalidSource): diff --git a/dom/media/platforms/wmf/WMFUtils.cpp b/dom/media/platforms/wmf/WMFUtils.cpp index b5747e3265..055012d0f5 100644 --- a/dom/media/platforms/wmf/WMFUtils.cpp +++ b/dom/media/platforms/wmf/WMFUtils.cpp @@ -210,12 +210,12 @@ MFStartup() return hr; } - const int MF_VERSION = (0x0002 << 16 | MF_API_VERSION); + const int MF_WIN7_VERSION = (0x0002 << 16 | MF_API_VERSION); // decltype is unusable for functions having default parameters DECL_FUNCTION_PTR(MFStartup, ULONG, DWORD); ENSURE_FUNCTION_PTR_(MFStartup, Mfplat.dll) - return MFStartupPtr(MF_VERSION, MFSTARTUP_FULL); + return MFStartupPtr(MF_WIN7_VERSION, MFSTARTUP_FULL); } HRESULT diff --git a/dom/security/nsCSPContext.cpp b/dom/security/nsCSPContext.cpp index 815c7734d0..5e435d4ca8 100644 --- a/dom/security/nsCSPContext.cpp +++ b/dom/security/nsCSPContext.cpp @@ -156,10 +156,13 @@ nsCSPContext::ShouldLoad(nsContentPolicyType aContentType, nsAutoString nonce; bool parserCreated = false; if (!isPreload) { - nsCOMPtr<nsIDOMHTMLElement> htmlElement = do_QueryInterface(aRequestContext); - if (htmlElement) { - rv = htmlElement->GetAttribute(NS_LITERAL_STRING("nonce"), nonce); - NS_ENSURE_SUCCESS(rv, rv); + if (aContentType == nsIContentPolicy::TYPE_SCRIPT || + aContentType == nsIContentPolicy::TYPE_STYLESHEET) { + nsCOMPtr<nsIDOMHTMLElement> htmlElement = do_QueryInterface(aRequestContext); + if (htmlElement) { + rv = htmlElement->GetAttribute(NS_LITERAL_STRING("nonce"), nonce); + NS_ENSURE_SUCCESS(rv, rv); + } } nsCOMPtr<nsIScriptElement> script = do_QueryInterface(aRequestContext); @@ -343,6 +346,20 @@ nsCSPContext::GetBlockAllMixedContent(bool *outBlockAllMixedContent) } NS_IMETHODIMP +nsCSPContext::GetEnforcesFrameAncestors(bool *outEnforcesFrameAncestors) +{ + *outEnforcesFrameAncestors = false; + for (uint32_t i = 0; i < mPolicies.Length(); i++) { + if (!mPolicies[i]->getReportOnlyFlag() && + mPolicies[i]->hasDirective(nsIContentSecurityPolicy::FRAME_ANCESTORS_DIRECTIVE)) { + *outEnforcesFrameAncestors = true; + return NS_OK; + } + } + return NS_OK; +} + +NS_IMETHODIMP nsCSPContext::GetReferrerPolicy(uint32_t* outPolicy, bool* outIsSet) { *outIsSet = false; diff --git a/dom/security/nsCSPParser.cpp b/dom/security/nsCSPParser.cpp index f1b5d8ba74..86aa4e0018 100644 --- a/dom/security/nsCSPParser.cpp +++ b/dom/security/nsCSPParser.cpp @@ -532,7 +532,7 @@ nsCSPParser::keywordSource() // Special case handling for 'self' which is not stored internally as a keyword, // but rather creates a nsCSPHostSrc using the selfURI if (CSP_IsKeyword(mCurToken, CSP_SELF)) { - return CSP_CreateHostSrcFromURI(mSelfURI); + return CSP_CreateHostSrcFromSelfURI(mSelfURI); } if (CSP_IsKeyword(mCurToken, CSP_STRICT_DYNAMIC)) { diff --git a/dom/security/nsCSPUtils.cpp b/dom/security/nsCSPUtils.cpp index b074a980c4..a5f683b018 100644 --- a/dom/security/nsCSPUtils.cpp +++ b/dom/security/nsCSPUtils.cpp @@ -266,20 +266,21 @@ CSP_ContentTypeToDirective(nsContentPolicyType aType) } nsCSPHostSrc* -CSP_CreateHostSrcFromURI(nsIURI* aURI) +CSP_CreateHostSrcFromSelfURI(nsIURI* aSelfURI) { // Create the host first nsCString host; - aURI->GetHost(host); + aSelfURI->GetAsciiHost(host); nsCSPHostSrc *hostsrc = new nsCSPHostSrc(NS_ConvertUTF8toUTF16(host)); + hostsrc->setGeneratedFromSelfKeyword(); // Add the scheme. nsCString scheme; - aURI->GetScheme(scheme); + aSelfURI->GetScheme(scheme); hostsrc->setScheme(NS_ConvertUTF8toUTF16(scheme)); int32_t port; - aURI->GetPort(&port); + aSelfURI->GetPort(&port); // Only add port if it's not default port. if (port > 0) { nsAutoString portStr; @@ -348,13 +349,17 @@ CSP_IsQuotelessKeyword(const nsAString& aKey) * @param aUpgradeInsecure * Whether the policy makes use of the directive * 'upgrade-insecure-requests'. + * @param aFromSelfURI + * Whether a scheme was generated from the keyword 'self' + * which then allows schemeless sources to match ws and wss. */ bool permitsScheme(const nsAString& aEnforcementScheme, nsIURI* aUri, bool aReportOnly, - bool aUpgradeInsecure) + bool aUpgradeInsecure, + bool aFromSelfURI) { nsAutoCString scheme; nsresult rv = aUri->GetScheme(scheme); @@ -373,8 +378,20 @@ permitsScheme(const nsAString& aEnforcementScheme, // allow scheme-less sources where the protected resource is http // and the load is https, see: // http://www.w3.org/TR/CSP2/#match-source-expression - if (aEnforcementScheme.EqualsASCII("http") && - scheme.EqualsASCII("https")) { + if (aEnforcementScheme.EqualsASCII("http")) { + if (scheme.EqualsASCII("https")) { + return true; + } + if ((scheme.EqualsASCII("ws") || scheme.EqualsASCII("wss")) && aFromSelfURI) { + return true; + } + } + if (aEnforcementScheme.EqualsASCII("https")) { + if (scheme.EqualsLiteral("wss") && aFromSelfURI) { + return true; + } + } + if (aEnforcementScheme.EqualsASCII("ws") && scheme.EqualsASCII("wss")) { return true; } @@ -483,7 +500,7 @@ nsCSPSchemeSrc::permits(nsIURI* aUri, const nsAString& aNonce, bool aWasRedirect if (mInvalidated) { return false; } - return permitsScheme(mScheme, aUri, aReportOnly, aUpgradeInsecure); + return permitsScheme(mScheme, aUri, aReportOnly, aUpgradeInsecure, false); } bool @@ -503,6 +520,7 @@ nsCSPSchemeSrc::toString(nsAString& outStr) const nsCSPHostSrc::nsCSPHostSrc(const nsAString& aHost) : mHost(aHost) + , mGeneratedFromSelfKeyword(false) , mWithinFrameAncstorsDir(false) { ToLowerCase(mHost); @@ -612,7 +630,7 @@ nsCSPHostSrc::permits(nsIURI* aUri, const nsAString& aNonce, bool aWasRedirected // http://www.w3.org/TR/CSP11/#match-source-expression // 4.3) scheme matching: Check if the scheme matches. - if (!permitsScheme(mScheme, aUri, aReportOnly, aUpgradeInsecure)) { + if (!permitsScheme(mScheme, aUri, aReportOnly, aUpgradeInsecure, mGeneratedFromSelfKeyword)) { return false; } @@ -643,7 +661,7 @@ nsCSPHostSrc::permits(nsIURI* aUri, const nsAString& aNonce, bool aWasRedirected // Before we can check if the host matches, we have to // extract the host part from aUri. nsAutoCString uriHost; - nsresult rv = aUri->GetHost(uriHost); + nsresult rv = aUri->GetAsciiHost(uriHost); NS_ENSURE_SUCCESS(rv, false); nsString decodedUriHost; diff --git a/dom/security/nsCSPUtils.h b/dom/security/nsCSPUtils.h index 468c734a22..cfbe832568 100644 --- a/dom/security/nsCSPUtils.h +++ b/dom/security/nsCSPUtils.h @@ -186,7 +186,7 @@ nsresult CSP_AppendCSPFromHeader(nsIContentSecurityPolicy* aCsp, class nsCSPHostSrc; -nsCSPHostSrc* CSP_CreateHostSrcFromURI(nsIURI* aURI); +nsCSPHostSrc* CSP_CreateHostSrcFromSelfURI(nsIURI* aSelfURI); bool CSP_IsValidDirective(const nsAString& aDir); bool CSP_IsDirective(const nsAString& aValue, CSPDirective aDir); bool CSP_IsKeyword(const nsAString& aValue, enum CSPKeyword aKey); @@ -256,6 +256,9 @@ class nsCSPHostSrc : public nsCSPBaseSrc { void setPort(const nsAString& aPort); void appendPath(const nsAString &aPath); + inline void setGeneratedFromSelfKeyword() const + { mGeneratedFromSelfKeyword = true;} + inline void setWithinFrameAncestorsDir(bool aValue) const { mWithinFrameAncstorsDir = aValue; } @@ -276,6 +279,7 @@ class nsCSPHostSrc : public nsCSPBaseSrc { nsString mHost; nsString mPort; nsString mPath; + mutable bool mGeneratedFromSelfKeyword; mutable bool mWithinFrameAncstorsDir; }; diff --git a/dom/security/test/csp/file_ignore_xfo.html b/dom/security/test/csp/file_ignore_xfo.html new file mode 100644 index 0000000000..6746a3adba --- /dev/null +++ b/dom/security/test/csp/file_ignore_xfo.html @@ -0,0 +1,10 @@ +<!DOCTYPE HTML> +<html> +<head> + <meta charset="utf-8"> + <title>Bug 1024557: Ignore x-frame-options if CSP with frame-ancestors exists</title> +</head> +<body> +<div id="cspmessage">Ignoring XFO because of CSP</div> +</body> +</html> diff --git a/dom/security/test/csp/file_ignore_xfo.html^headers^ b/dom/security/test/csp/file_ignore_xfo.html^headers^ new file mode 100644 index 0000000000..e93f9e3ecb --- /dev/null +++ b/dom/security/test/csp/file_ignore_xfo.html^headers^ @@ -0,0 +1,3 @@ +Content-Security-Policy: frame-ancestors http://mochi.test:8888 +X-Frame-Options: deny +Cache-Control: no-cache diff --git a/dom/security/test/csp/file_image_nonce.html b/dom/security/test/csp/file_image_nonce.html new file mode 100644 index 0000000000..5d57bb8372 --- /dev/null +++ b/dom/security/test/csp/file_image_nonce.html @@ -0,0 +1,39 @@ +<!DOCTYPE HTML> +<html> + <head> + <meta charset='utf-8'> + <title>Bug 1355801: Nonce should not apply to images</title> + </head> +<body> + +<img id='matchingNonce' src='http://mochi.test:8888/tests/image/test/mochitest/blue.png?a' nonce='abc'></img> +<img id='nonMatchingNonce' src='http://mochi.test:8888/tests/image/test/mochitest/blue.png?b' nonce='bca'></img> +<img id='noNonce' src='http://mochi.test:8888/tests/image/test/mochitest/blue.png?c'></img> + +<script type='application/javascript'> + var matchingNonce = document.getElementById('matchingNonce'); + matchingNonce.onload = function(e) { + window.parent.postMessage({result: 'img-with-matching-nonce-loaded'}, '*'); + }; + matchingNonce.onerror = function(e) { + window.parent.postMessage({result: 'img-with-matching-nonce-blocked'}, '*'); + } + + var nonMatchingNonce = document.getElementById('nonMatchingNonce'); + nonMatchingNonce.onload = function(e) { + window.parent.postMessage({result: 'img-with_non-matching-nonce-loaded'}, '*'); + }; + nonMatchingNonce.onerror = function(e) { + window.parent.postMessage({result: 'img-with_non-matching-nonce-blocked'}, '*'); + } + + var noNonce = document.getElementById('noNonce'); + noNonce.onload = function(e) { + window.parent.postMessage({result: 'img-without-nonce-loaded'}, '*'); + }; + noNonce.onerror = function(e) { + window.parent.postMessage({result: 'img-without-nonce-blocked'}, '*'); + } +</script> +</body> +</html> diff --git a/dom/security/test/csp/file_image_nonce.html^headers^ b/dom/security/test/csp/file_image_nonce.html^headers^ new file mode 100644 index 0000000000..0d63558c46 --- /dev/null +++ b/dom/security/test/csp/file_image_nonce.html^headers^ @@ -0,0 +1,2 @@ +Content-Security-Policy: img-src 'nonce-abc'; +Cache-Control: no-cache diff --git a/dom/security/test/csp/file_punycode_host_src.js b/dom/security/test/csp/file_punycode_host_src.js new file mode 100644 index 0000000000..3505faf70d --- /dev/null +++ b/dom/security/test/csp/file_punycode_host_src.js @@ -0,0 +1,2 @@ +const LOADED = true; +parent.postMessage({result: 'script-allowed'}, "*");
\ No newline at end of file diff --git a/dom/security/test/csp/file_punycode_host_src.sjs b/dom/security/test/csp/file_punycode_host_src.sjs new file mode 100644 index 0000000000..3189cc063a --- /dev/null +++ b/dom/security/test/csp/file_punycode_host_src.sjs @@ -0,0 +1,45 @@ +// custom *.sjs for Bug 1224225 +// Punycode in CSP host sources + +const HTML_PART1 = + "<!DOCTYPE HTML>" + + "<html><head><meta charset=\"utf-8\">" + + "<title>Bug 1224225 - CSP source matching should work for punycoded domain names</title>" + + "</head>" + + "<body>" + + "<script id='script' src='"; + +const TESTCASE1 = "http://sub2.ält.example.org/"; +const TESTCASE2 = "http://sub2.xn--lt-uia.example.org/" + +const HTML_PART2 = "tests/dom/security/test/csp/file_punycode_host_src.js'></script>" + + "</body>" + + "</html>"; + +function handleRequest(request, response) +{ + // avoid confusing cache behaviors + response.setHeader("Cache-Control", "no-cache", false); + response.setHeader("Content-Type", "text/html", false); + + Components.utils.importGlobalProperties(["URLSearchParams"]); + const query = new URLSearchParams(request.queryString); + + + if (query.get("csp")) { + response.setHeader("Content-Security-Policy", query.get("csp"), false); + } + if (query.get("action") == "script-unicode-csp-punycode") { + response.write(HTML_PART1 + TESTCASE1 + HTML_PART2); + return + } + if (query.get("action") == "script-punycode-csp-punycode") { + response.write(HTML_PART1 + TESTCASE2 + HTML_PART2); + return + } + + + // we should never get here, but just in case + // return something unexpected + response.write("do'h"); +} diff --git a/dom/security/test/csp/file_ro_ignore_xfo.html b/dom/security/test/csp/file_ro_ignore_xfo.html new file mode 100644 index 0000000000..85e7f0092c --- /dev/null +++ b/dom/security/test/csp/file_ro_ignore_xfo.html @@ -0,0 +1,10 @@ +<!DOCTYPE HTML> +<html> +<head> + <meta charset="utf-8"> + <title>Bug 1024557: Ignore x-frame-options if CSP with frame-ancestors exists</title> +</head> +<body> +<div id="cspmessage">Ignoring XFO because of CSP_RO</div> +</body> +</html>
\ No newline at end of file diff --git a/dom/security/test/csp/file_ro_ignore_xfo.html^headers^ b/dom/security/test/csp/file_ro_ignore_xfo.html^headers^ new file mode 100644 index 0000000000..ab8366f061 --- /dev/null +++ b/dom/security/test/csp/file_ro_ignore_xfo.html^headers^ @@ -0,0 +1,3 @@ +Content-Security-Policy-Report-Only: frame-ancestors http://mochi.test:8888 +X-Frame-Options: deny +Cache-Control: no-cache diff --git a/dom/security/test/csp/file_upgrade_insecure_navigation.sjs b/dom/security/test/csp/file_upgrade_insecure_navigation.sjs new file mode 100644 index 0000000000..51afa39bf7 --- /dev/null +++ b/dom/security/test/csp/file_upgrade_insecure_navigation.sjs @@ -0,0 +1,79 @@ +// Custom *.sjs file specifically for the needs of +// https://bugzilla.mozilla.org/show_bug.cgi?id=1271173 + +"use strict"; +Components.utils.importGlobalProperties(["URLSearchParams"]); + +const TEST_NAVIGATIONAL_UPGRADE = ` + <!DOCTYPE html> + <html> + <head><meta charset="utf-8"></head> + <body> + <a href="http://example.com/tests/dom/security/test/csp/file_upgrade_insecure_navigation.sjs?action=framenav" id="testlink">clickme</a> + <script type="text/javascript"> + // before navigating the current frame we open the window and check that uir applies + var myWin = window.open("http://example.com/tests/dom/security/test/csp/file_upgrade_insecure_navigation.sjs?action=docnav"); + + window.addEventListener("message", receiveMessage, false); + function receiveMessage(event) { + myWin.close(); + var link = document.getElementById('testlink'); + link.click(); + } + </script> + </body> + </html>`; + +const FRAME_NAV = ` + <!DOCTYPE html> + <html> + <head><meta charset="utf-8"></head> + <body> + <script type="text/javascript"> + parent.postMessage({result: document.documentURI}, "*"); + </script> + </body> + </html>`; + +const DOC_NAV = ` + <!DOCTYPE html> + <html> + <head><meta charset="utf-8"></head> + <body> + <script type="text/javascript"> + // call back to the main testpage signaling whether the upgraded succeeded + window.opener.parent.postMessage({result: document.documentURI}, "*"); + // let the opener (iframe) now that we can now close the window and move on with the test. + window.opener.postMessage({result: "readyToMoveOn"}, "*"); + </script> + </body> + </html>`; + +function handleRequest(request, response) { + const query = new URLSearchParams(request.queryString); + + response.setHeader("Cache-Control", "no-cache", false); + response.setHeader("Content-Type", "text/html", false); + if (query.get("csp")) { + response.setHeader("Content-Security-Policy", query.get("csp"), false); + } + + if (query.get("action") === "perform_navigation") { + response.write(TEST_NAVIGATIONAL_UPGRADE); + return; + } + + if (query.get("action") === "framenav") { + response.write(FRAME_NAV); + return; + } + + if (query.get("action") === "docnav") { + response.write(DOC_NAV); + return; + } + + // we should never get here, but just in case + // return something unexpected + response.write("do'h"); +} diff --git a/dom/security/test/csp/file_websocket_explicit.html b/dom/security/test/csp/file_websocket_explicit.html new file mode 100644 index 0000000000..51462ab741 --- /dev/null +++ b/dom/security/test/csp/file_websocket_explicit.html @@ -0,0 +1,31 @@ +<!DOCTYPE HTML>
+<html>
+<head>
+ <meta charset="utf-8">
+ <title>Bug 1345615: Allow websocket schemes when using 'self' in CSP</title>
+ <meta http-equiv="Content-Security-Policy" content="connect-src ws:">
+</head>
+<body>
+ <script type="application/javascript">
+ /* load socket using ws */
+ var wsSocket = new WebSocket("ws://example.com/tests/dom/security/test/csp/file_websocket_self");
+ wsSocket.onopen = function(e) {
+ window.parent.postMessage({result: "explicit-ws-loaded"}, "*");
+ wsSocket.close();
+ };
+ wsSocket.onerror = function(e) {
+ window.parent.postMessage({result: "explicit-ws-blocked"}, "*");
+ };
+
+ /* load socket using wss */
+ var wssSocket = new WebSocket("wss://example.com/tests/dom/security/test/csp/file_websocket_self");
+ wssSocket.onopen = function(e) {
+ window.parent.postMessage({result: "explicit-wss-loaded"}, "*");
+ wssSocket.close();
+ };
+ wssSocket.onerror = function(e) {
+ window.parent.postMessage({result: "explicit-wss-blocked"}, "*");
+ };
+ </script>
+</body>
+</html>
diff --git a/dom/security/test/csp/file_websocket_self.html b/dom/security/test/csp/file_websocket_self.html new file mode 100644 index 0000000000..3ff5f05580 --- /dev/null +++ b/dom/security/test/csp/file_websocket_self.html @@ -0,0 +1,31 @@ +<!DOCTYPE HTML>
+<html>
+<head>
+ <meta charset="utf-8">
+ <title>Bug 1345615: Allow websocket schemes when using 'self' in CSP</title>
+ <meta http-equiv="Content-Security-Policy" content="connect-src 'self'">
+</head>
+<body>
+ <script type="application/javascript">
+ /* load socket using ws */
+ var wsSocket = new WebSocket("ws://example.com/tests/dom/security/test/csp/file_websocket_self");
+ wsSocket.onopen = function(e) {
+ window.parent.postMessage({result: "self-ws-loaded"}, "*");
+ wsSocket.close();
+ };
+ wsSocket.onerror = function(e) {
+ window.parent.postMessage({result: "self-ws-blocked"}, "*");
+ };
+
+ /* load socket using wss */
+ var wssSocket = new WebSocket("wss://example.com/tests/dom/security/test/csp/file_websocket_self");
+ wssSocket.onopen = function(e) {
+ window.parent.postMessage({result: "self-wss-loaded"}, "*");
+ wssSocket.close();
+ };
+ wssSocket.onerror = function(e) {
+ window.parent.postMessage({result: "self-wss-blocked"}, "*");
+ };
+ </script>
+</body>
+</html>
diff --git a/dom/security/test/csp/file_websocket_self_wsh.py b/dom/security/test/csp/file_websocket_self_wsh.py new file mode 100644 index 0000000000..5fe508a910 --- /dev/null +++ b/dom/security/test/csp/file_websocket_self_wsh.py @@ -0,0 +1,7 @@ +from mod_pywebsocket import msgutil
+
+def web_socket_do_extra_handshake(request):
+ pass
+
+def web_socket_transfer_data(request):
+ pass
diff --git a/dom/security/test/csp/mochitest.ini b/dom/security/test/csp/mochitest.ini index 8add999c30..2102cbe706 100644 --- a/dom/security/test/csp/mochitest.ini +++ b/dom/security/test/csp/mochitest.ini @@ -206,6 +206,18 @@ support-files = file_iframe_srcdoc.sjs file_iframe_sandbox_srcdoc.html file_iframe_sandbox_srcdoc.html^headers^ + file_ignore_xfo.html + file_ignore_xfo.html^headers^ + file_ro_ignore_xfo.html + file_ro_ignore_xfo.html^headers^ + file_upgrade_insecure_navigation.sjs + file_image_nonce.html + file_image_nonce.html^headers^ + file_punycode_host_src.sjs + file_punycode_host_src.js + file_websocket_self.html + file_websocket_explicit.html + file_websocket_self_wsh.py [test_base-uri.html] [test_blob_data_schemes.html] @@ -292,9 +304,15 @@ tags = mcb [test_strict_dynamic.html] [test_strict_dynamic_parser_inserted.html] [test_strict_dynamic_default_src.html] +[test_upgrade_insecure_navigation.html] [test_iframe_sandbox_srcdoc.html] [test_iframe_srcdoc.html] [test_sandbox_allow_scripts.html] support-files = file_sandbox_allow_scripts.html file_sandbox_allow_scripts.html^headers^ +[test_ignore_xfo.html] +[test_image_nonce.html] +[test_punycode_host_src.html] +[test_websocket_self.html] +skip-if = toolkit == 'android' diff --git a/dom/security/test/csp/test_ignore_xfo.html b/dom/security/test/csp/test_ignore_xfo.html new file mode 100644 index 0000000000..fb3aadc6c2 --- /dev/null +++ b/dom/security/test/csp/test_ignore_xfo.html @@ -0,0 +1,59 @@ +<!DOCTYPE HTML> +<html> +<head> + <title>Bug 1024557: Ignore x-frame-options if CSP with frame-ancestors exists</title> + <!-- Including SimpleTest.js so we can use waitForExplicitFinish !--> + <script type="text/javascript" src="/tests/SimpleTest/SimpleTest.js"></script> + <link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css" /> +</head> +<body> +<iframe style="width:100%;" id="csp_testframe"></iframe> +<iframe style="width:100%;" id="csp_ro_testframe"></iframe> + +<script class="testbody" type="text/javascript"> + +/* + * We load two frames using: + * x-frame-options: deny + * where the first frame uses a csp and the second a csp_ro including frame-ancestors. + * We make sure that xfo is ignored for regular csp but not for csp_ro. + */ + +SimpleTest.waitForExplicitFinish(); + +var testcounter = 0; +function checkFinished() { + testcounter++; + if (testcounter < 2) { + return; + } + SimpleTest.finish(); +} + +// 1) test XFO with CSP +var csp_testframe = document.getElementById("csp_testframe"); +csp_testframe.onload = function() { + var msg = csp_testframe.contentWindow.document.getElementById("cspmessage"); + is(msg.innerHTML, "Ignoring XFO because of CSP", "Loading frame with with XFO and CSP"); + checkFinished(); +} +csp_testframe.onerror = function() { + ok(false, "sanity: should not fire onerror for csp_testframe"); +} +csp_testframe.src = "file_ignore_xfo.html"; + +// 2) test XFO with CSP_RO +var csp_ro_testframe = document.getElementById("csp_ro_testframe"); +csp_ro_testframe.onload = function() { + var msg = csp_ro_testframe.contentWindow.document.getElementById("cspmessage"); + is(msg, null, "Blocking frame with with XFO and CSP_RO"); + checkFinished(); +} +csp_ro_testframe.onerror = function() { + ok(false, "sanity: should not fire onerror for csp_ro_testframe"); +} +csp_ro_testframe.src = "file_ro_ignore_xfo.html"; + +</script> +</body> +</html> diff --git a/dom/security/test/csp/test_image_nonce.html b/dom/security/test/csp/test_image_nonce.html new file mode 100644 index 0000000000..ff6d636b6d --- /dev/null +++ b/dom/security/test/csp/test_image_nonce.html @@ -0,0 +1,60 @@ +<!DOCTYPE HTML> +<html> +<head> + <meta charset="utf-8"> + <title>Bug 1139297 - Implement CSP upgrade-insecure-requests directive</title> + <!-- Including SimpleTest.js so we can use waitForExplicitFinish !--> + <script type="text/javascript" src="/tests/SimpleTest/SimpleTest.js"></script> + <link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css" /> +</head> +<body> +<iframe style="width:100%;" id="testframe"></iframe> + +<script class="testbody" type="text/javascript"> + +/* Description of the test: + * We load three images: (a) with a matching nonce, + (b) with a non matching nonce, + * (c) with no nonce + * and make sure that all three images get blocked because + * "img-src nonce-bla" should not allow an image load, not + * even if the nonce matches*. + */ + +SimpleTest.waitForExplicitFinish(); + +var counter = 0; + +function finishTest() { + window.removeEventListener("message", receiveMessage); + SimpleTest.finish(); +} + +function checkResults(aResult) { + counter++; + if (aResult === "img-with-matching-nonce-blocked" || + aResult === "img-with_non-matching-nonce-blocked" || + aResult === "img-without-nonce-blocked") { + ok (true, "correct result for: " + aResult); + } + else { + ok(false, "unexpected result: " + aResult + "\n\n"); + } + if (counter < 3) { + return; + } + finishTest(); +} + +// a postMessage handler that is used by sandboxed iframes without +// 'allow-same-origin' to bubble up results back to this main page. +window.addEventListener("message", receiveMessage); +function receiveMessage(event) { + checkResults(event.data.result); +} + +document.getElementById("testframe").src = "file_image_nonce.html"; + +</script> +</body> +</html> diff --git a/dom/security/test/csp/test_punycode_host_src.html b/dom/security/test/csp/test_punycode_host_src.html new file mode 100644 index 0000000000..8d891725c3 --- /dev/null +++ b/dom/security/test/csp/test_punycode_host_src.html @@ -0,0 +1,81 @@ +<!DOCTYPE HTML> +<html> +<head> + <meta charset="utf-8"> + <title>Bug 1224225 - CSP source matching should work for punycoded domain names</title> + <!-- Including SimpleTest.js so we can use waitForExplicitFinish !--> + <script type="text/javascript" src="/tests/SimpleTest/SimpleTest.js"></script> + <link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css" /> +</head> +<body> +<iframe style="width:100%;" id="testframe"></iframe> + +<script class="testbody" type="text/javascript"> + +/* Description of the test: + * We load scripts within an iframe and make sure that the + * CSP matching is same for punycode domain names as well as IDNA. + */ + +SimpleTest.waitForExplicitFinish(); + + +var curTest; +var counter = -1; + +const tests = [ + { // test 1 + description: "loads script as sub2.ält.example.org, but whitelist in CSP as sub2.xn--lt-uia.example.org", + action: "script-unicode-csp-punycode", + csp: "script-src http://sub2.xn--lt-uia.example.org;", + expected: "script-allowed", + + }, + { // test 2 + description: "loads script as sub2.xn--lt-uia.example.org, and whitelist in CSP as sub2.xn--lt-uia.example.org", + action: "script-punycode-csp-punycode", + csp: "script-src http://sub2.xn--lt-uia.example.org;", + expected: "script-allowed", + + }, + { // test 3 + description: "loads script as sub2.xn--lt-uia.example.org, and whitelist in CSP as sub2.xn--lt-uia.example.org", + action: "script-punycode-csp-punycode", + csp: "script-src *.xn--lt-uia.example.org;", + expected: "script-allowed", + + }, + +]; + +function finishTest() { + window.removeEventListener("message", receiveMessage); + SimpleTest.finish(); +} + +function checkResults(result) { + is(result, curTest.expected, curTest.description); + loadNextTest(); +} + +window.addEventListener("message", receiveMessage); +function receiveMessage(event) { + checkResults(event.data.result); +} + +function loadNextTest() { + counter++; + if (counter == tests.length) { + finishTest(); + return; + } + curTest = tests[counter]; + var testframe = document.getElementById("testframe"); + testframe.src = `file_punycode_host_src.sjs?action=${curTest.action}&csp=${curTest.csp}`; +} + +loadNextTest(); + +</script> +</body> +</html> diff --git a/dom/security/test/csp/test_upgrade_insecure_navigation.html b/dom/security/test/csp/test_upgrade_insecure_navigation.html new file mode 100644 index 0000000000..db6a6a1bed --- /dev/null +++ b/dom/security/test/csp/test_upgrade_insecure_navigation.html @@ -0,0 +1,103 @@ +<!DOCTYPE HTML> +<html> +<head> + <title>Bug 1271173 - Missing spec on Upgrade Insecure Requests(Navigational Upgrades) </title> + <!-- Including SimpleTest.js so we can use waitForExplicitFinish !--> + <script type="text/javascript" src="/tests/SimpleTest/SimpleTest.js"></script> + <link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css" /> +</head> +<body> +<iframe style="width:100%;" id="testframe"></iframe> +<iframe style="width:100%;" id="sandboxedtestframe" + sandbox="allow-scripts allow-top-navigation allow-same-origin allow-pointer-lock allow-popups"></iframe> + +<script class="testbody" type="text/javascript"> +/* + * Description of the test: + * We load a page into an iframe that performs a navigational request. + * We make sure that upgrade-insecure-requests applies and the page + * gets upgraded to https if same origin. + * Please note that uir only applies to sandboxed iframes if + * the value 'allow-same-origin' is specified. + */ + +SimpleTest.waitForExplicitFinish(); + +var tests = [ + { + csp: "upgrade-insecure-requests;", + result: "https", + origin: "http://example.com", + desc: "upgrade-insecure-requests same origin should upgrade" + }, + { + csp: "", + result: "http", + origin: "http://example.com", + desc: "No upgrade-insecure-requests same origin should not upgrade" + }, + { + csp: "upgrade-insecure-requests;", + result: "http", + origin: "http://mochi.test:8888", + desc: "upgrade-insecure-requests cross origin should not upgrade" + }, + { + csp: "", + result: "http", + origin: "http://mochi.test:8888", + desc: "No upgrade-insecure-requests cross origin should not upgrade" + }, +]; + +// initializing to -1 so we start at index 0 when we start the test +var counter = -1; + +function finishTest() { + window.removeEventListener("message", receiveMessage, false); + SimpleTest.finish(); +} + +var subtests = 0; + +window.addEventListener("message", receiveMessage, false); +function receiveMessage(event) { + var result = event.data.result; + // query the scheme from the URL before comparing the result + var scheme = result.substring(0, result.indexOf(":")); + is(scheme, tests[counter].result, tests[counter].desc); + + // @hardcoded 4: + // each test run contains of two subtests (frame and top-level) + // and we load each test into a regular iframe and into a + // sandboxed iframe. only move on to the next test once all + // four results from the subtests have bubbled up. + subtests++; + if (subtests != 4) { + return; + } + subtests = 0; + loadNextTest(); +} + +function loadNextTest() { + counter++; + if (counter == tests.length) { + finishTest(); + return; + } + + var src = tests[counter].origin; + src += "/tests/dom/security/test/csp/file_upgrade_insecure_navigation.sjs"; + src += "?csp=" + escape(tests[counter].csp); + src += "&action=perform_navigation"; + document.getElementById("testframe").src = src; + document.getElementById("sandboxedtestframe").src = src; +} + +// start running the tests +loadNextTest(); + +</script> +</body> +</html> diff --git a/dom/security/test/csp/test_websocket_self.html b/dom/security/test/csp/test_websocket_self.html new file mode 100644 index 0000000000..a03c32704e --- /dev/null +++ b/dom/security/test/csp/test_websocket_self.html @@ -0,0 +1,61 @@ +<!DOCTYPE HTML>
+<html>
+<head>
+ <meta charset="utf-8">
+ <title>Bug 1345615: Allow websocket schemes when using 'self' in CSP</title>
+ <!-- Including SimpleTest.js so we can use waitForExplicitFinish !-->
+ <script type="text/javascript" src="/tests/SimpleTest/SimpleTest.js"></script>
+ <link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css" />
+</head>
+<body>
+<iframe style="width:100%;" id="test_ws_self_frame"></iframe>
+<iframe style="width:100%;" id="test_ws_explicit_frame"></iframe>
+
+<script class="testbody" type="text/javascript">
+
+/* Description of the test:
+ * We load an iframe using connect-src 'self' and one
+ * iframe using connect-src ws: and make
+ * sure that in both cases ws: as well as wss: is allowed to load.
+ */
+
+SimpleTest.waitForExplicitFinish();
+
+function finishTest() {
+ window.removeEventListener("message", receiveMessage);
+ SimpleTest.finish();
+}
+
+const TOTAL_TESTS = 4;
+var counter = 0;
+
+function checkResults(result) {
+ counter++;
+ if (result === "self-ws-loaded" || result === "self-wss-loaded" ||
+ result === "explicit-ws-loaded" || result === "explicit-wss-loaded") {
+ ok(true, "Evaluating: " + result);
+ }
+ else {
+ ok(false, "Evaluating: " + result);
+ }
+ if (counter < TOTAL_TESTS) {
+ return;
+ }
+ finishTest();
+}
+
+window.addEventListener("message", receiveMessage);
+function receiveMessage(event) {
+ checkResults(event.data.result);
+}
+
+const HOST = "http://example.com/tests/dom/security/test/csp/";
+var test_ws_self_frame = document.getElementById("test_ws_self_frame");
+test_ws_self_frame.src = HOST + "file_websocket_self.html";
+
+var test_ws_explicit_frame = document.getElementById("test_ws_explicit_frame");
+test_ws_explicit_frame.src = HOST + "file_websocket_explicit.html";
+
+</script>
+</body>
+</html>
diff --git a/dom/security/test/gtest/TestCSPParser.cpp b/dom/security/test/gtest/TestCSPParser.cpp index fafa7b5d95..8d168d81cb 100644 --- a/dom/security/test/gtest/TestCSPParser.cpp +++ b/dom/security/test/gtest/TestCSPParser.cpp @@ -204,6 +204,8 @@ TEST(CSPParser, Directives) { static const PolicyTest policies[] = { + { "connect-src xn--mnchen-3ya.de", + "connect-src http://xn--mnchen-3ya.de"}, { "default-src http://www.example.com", "default-src http://www.example.com" }, { "script-src http://www.example.com", diff --git a/dom/tests/mochitest/general/test_domWindowUtils_scrollXY.html b/dom/tests/mochitest/general/test_domWindowUtils_scrollXY.html index c6ee89ee35..cf27e5d87f 100644 --- a/dom/tests/mochitest/general/test_domWindowUtils_scrollXY.html +++ b/dom/tests/mochitest/general/test_domWindowUtils_scrollXY.html @@ -31,13 +31,13 @@ function checkGetScrollXYState(flush, vals, testName) { let scrollX = {}, scrollY = {}; domWindowUtils.getScrollXY(flush, scrollX, scrollY); - is(scrollX.value, vals[0], "getScrollXY x for test: " + testName); - is(scrollY.value, vals[1], "getScrollXY y for test: " + testName); + is(Math.round(scrollX.value), vals[0], "getScrollXY x for test: " + testName); + is(Math.round(scrollY.value), vals[1], "getScrollXY y for test: " + testName); } function checkWindowScrollState(vals, testName) { - is(cwindow.scrollX, vals[0], "scrollX for test: " + testName); - is(cwindow.scrollY, vals[1], "scrollY for test: " + testName); + is(Math.round(cwindow.scrollX), vals[0], "scrollX for test: " + testName); + is(Math.round(cwindow.scrollY), vals[1], "scrollY for test: " + testName); } // Check initial state (0, 0) @@ -67,8 +67,8 @@ let scrollX = {}, scrollY = {}; domWindowUtils.getScrollXY(false, scrollX, scrollY); - is(scrollX.value, 0, "scrollX is zero for display:none iframe"); - is(scrollY.value, 0, "scrollY is zero for display:none iframe"); + is(Math.round(scrollX.value), 0, "scrollX is zero for display:none iframe"); + is(Math.round(scrollY.value), 0, "scrollY is zero for display:none iframe"); } SimpleTest.waitForExplicitFinish(); diff --git a/dom/url/URL.h b/dom/url/URL.h index 16b4678baf..45e4dd2894 100644 --- a/dom/url/URL.h +++ b/dom/url/URL.h @@ -155,6 +155,12 @@ public: GetHref(aRetval, aRv); } + void + ToJSON(nsAString& aResult, ErrorResult& aRv) const + { + GetHref(aResult, aRv); + } + // URLSearchParamsObserver void URLSearchParamsUpdated(URLSearchParams* aSearchParams) override; diff --git a/dom/url/tests/test_url.html b/dom/url/tests/test_url.html index 3f3f727d63..d07a752bb4 100644 --- a/dom/url/tests/test_url.html +++ b/dom/url/tests/test_url.html @@ -438,5 +438,11 @@ url = new URL("data:text/html,<a href=\"http://example.org/?q\">Link</a>"); is(url.href, "data:text/html,<a%20href=\"http://example.org/?q\">Link</a>"); </script> + + <script> + var u = new URL('http://www.example.org'); + ok(u.toJSON(), 'http://www.example.org', "URL.toJSON()"); + is(JSON.stringify(u), "\"http://www.example.org/\"", "JSON.stringify(u) works"); + </script> </body> </html> diff --git a/dom/webidl/URL.webidl b/dom/webidl/URL.webidl index 0baa9913c1..4d491e1b36 100644 --- a/dom/webidl/URL.webidl +++ b/dom/webidl/URL.webidl @@ -44,9 +44,12 @@ interface URL { attribute USVString pathname; [Throws] attribute USVString search; - readonly attribute URLSearchParams searchParams; + [SameObject] readonly attribute URLSearchParams searchParams; [Throws] attribute USVString hash; + + [Throws] + USVString toJSON(); }; partial interface URL { diff --git a/dom/webidl/Window.webidl b/dom/webidl/Window.webidl index 055a274cc1..36b1f0313b 100644 --- a/dom/webidl/Window.webidl +++ b/dom/webidl/Window.webidl @@ -182,14 +182,10 @@ partial interface Window { [ChromeOnly] void mozScrollSnap(); // The four properties below are double per spec at the moment, but whether // that will continue is unclear. - //[Replaceable, Throws] readonly attribute double scrollX; - //[Replaceable, Throws] readonly attribute double pageXOffset; - //[Replaceable, Throws] readonly attribute double scrollY; - //[Replaceable, Throws] readonly attribute double pageYOffset; - [Replaceable, Throws] readonly attribute long scrollX; - [Replaceable, Throws] readonly attribute long pageXOffset; - [Replaceable, Throws] readonly attribute long scrollY; - [Replaceable, Throws] readonly attribute long pageYOffset; + [Replaceable, Throws] readonly attribute double scrollX; + [Throws] readonly attribute double pageXOffset; + [Replaceable, Throws] readonly attribute double scrollY; + [Throws] readonly attribute double pageYOffset; // client // These are writable because we allow chrome to write them. And they need diff --git a/layout/forms/test/test_bug562447.html b/layout/forms/test/test_bug562447.html index 53f84428e5..99f6918711 100644 --- a/layout/forms/test/test_bug562447.html +++ b/layout/forms/test/test_bug562447.html @@ -23,7 +23,7 @@ addLoadEvent(function() { setTimeout(function() { // Make sure that we're scrolled by 5000px - is(window.pageYOffset, 5000, "Make sure we're scrolled correctly"); + is(Math.round(window.pageYOffset), 5000, "Make sure we're scrolled correctly"); // Scroll back up, and mess with the input box along the way var input = document.getElementById("WhyDoYouFocusMe"); @@ -38,14 +38,14 @@ addLoadEvent(function() { window.scrollTo(0, 5000); setTimeout(function() { - is(window.pageYOffset, 5000, "Sanity check"); + is(Math.round(window.pageYOffset), 5000, "Sanity check"); window.scrollTo(0, 0); input.focus(); input.blur(); setTimeout(function() { - isnot(window.pageYOffset, 0, "This time we shouldn't be scrolled up"); + isnot(Math.round(window.pageYOffset), 0, "This time we shouldn't be scrolled up"); SimpleTest.finish(); }, 0); diff --git a/layout/forms/test/test_bug564115.html b/layout/forms/test/test_bug564115.html index 5723b55d5a..ffd4222cae 100644 --- a/layout/forms/test/test_bug564115.html +++ b/layout/forms/test/test_bug564115.html @@ -30,12 +30,12 @@ addLoadEvent(function() { win.scrollTo(0, 5000); setTimeout(function() { - is(win.pageYOffset, 5000, "Page should be scrolled correctly"); + is(Math.round(win.pageYOffset), 5000, "Page should be scrolled correctly"); // Refocus the window SimpleTest.waitForFocus(function() { SimpleTest.waitForFocus(function() { - is(win.pageYOffset, 5000, + is(Math.round(win.pageYOffset), 5000, "The page's scroll offset should not have been changed"); win.close(); diff --git a/layout/style/nsMediaFeatures.cpp b/layout/style/nsMediaFeatures.cpp index 052ce58e84..5a54d5455d 100644 --- a/layout/style/nsMediaFeatures.cpp +++ b/layout/style/nsMediaFeatures.cpp @@ -70,8 +70,6 @@ struct OperatingSystemVersionInfo { // Os version identities used in the -moz-os-version media query. const OperatingSystemVersionInfo osVersionStrings[] = { - { LookAndFeel::eOperatingSystemVersion_WindowsXP, L"windows-xp" }, - { LookAndFeel::eOperatingSystemVersion_WindowsVista, L"windows-vista" }, { LookAndFeel::eOperatingSystemVersion_Windows7, L"windows-win7" }, { LookAndFeel::eOperatingSystemVersion_Windows8, L"windows-win8" }, { LookAndFeel::eOperatingSystemVersion_Windows10, L"windows-win10" } diff --git a/layout/style/test/chrome/bug418986-2.js b/layout/style/test/chrome/bug418986-2.js index 4336f4abdb..b083f48ee6 100644 --- a/layout/style/test/chrome/bug418986-2.js +++ b/layout/style/test/chrome/bug418986-2.js @@ -53,8 +53,6 @@ var suppressed_toggles = [ // Possible values for '-moz-os-version' var windows_versions = [ - "windows-xp", - "windows-vista", "windows-win7", "windows-win8", "windows-win10", diff --git a/layout/style/test/test_media_queries.html b/layout/style/test/test_media_queries.html index 479306a55a..d503fad0b2 100644 --- a/layout/style/test/test_media_queries.html +++ b/layout/style/test/test_media_queries.html @@ -713,8 +713,6 @@ function run() { expression_should_not_be_parseable("-moz-windows-theme: "); // os version media queries (currently windows only) - expression_should_be_parseable("-moz-os-version: windows-xp"); - expression_should_be_parseable("-moz-os-version: windows-vista"); 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"); diff --git a/modules/libpref/init/all.js b/modules/libpref/init/all.js index aaf50bff66..53891c6086 100644 --- a/modules/libpref/init/all.js +++ b/modules/libpref/init/all.js @@ -21,7 +21,10 @@ pref("keyword.enabled", false); pref("general.useragent.locale", "chrome://global/locale/intl.properties"); +pref("general.useragent.compatMode.gecko", false); pref("general.useragent.compatMode.firefox", false); +pref("general.useragent.compatMode.version", "52.9"); +pref("general.useragent.appVersionIsBuildID", true); // This pref exists only for testing purposes. In order to disable all // overrides by default, don't initialize UserAgentOverrides.jsm. diff --git a/netwerk/base/LoadInfo.cpp b/netwerk/base/LoadInfo.cpp index 216cf559cd..42fdea4a18 100644 --- a/netwerk/base/LoadInfo.cpp +++ b/netwerk/base/LoadInfo.cpp @@ -859,6 +859,12 @@ LoadInfo::SetIsPreflight() mIsPreflight = true; } +void +LoadInfo::SetUpgradeInsecureRequests() +{ + mUpgradeInsecureRequests = true; +} + NS_IMETHODIMP LoadInfo::GetIsPreflight(bool* aIsPreflight) { diff --git a/netwerk/base/LoadInfo.h b/netwerk/base/LoadInfo.h index 261f85349d..3e1b92ff4c 100644 --- a/netwerk/base/LoadInfo.h +++ b/netwerk/base/LoadInfo.h @@ -78,6 +78,7 @@ public: already_AddRefed<nsILoadInfo> CloneForNewRequest() const; void SetIsPreflight(); + void SetUpgradeInsecureRequests(); private: // private constructor that is only allowed to be called from within diff --git a/netwerk/base/nsICryptoHash.idl b/netwerk/base/nsICryptoHash.idl index cd865a3a9d..ddd3103af7 100644 --- a/netwerk/base/nsICryptoHash.idl +++ b/netwerk/base/nsICryptoHash.idl @@ -10,7 +10,7 @@ interface nsIInputStream; * This interface provides crytographic hashing algorithms. */ -[scriptable, uuid(1e5b7c43-4688-45ce-92e1-77ed931e3bbe)] +[scriptable, uuid(0a248513-dfa7-4474-8777-8c452d60dd04)] interface nsICryptoHash : nsISupports { /** @@ -25,6 +25,7 @@ interface nsICryptoHash : nsISupports const short SHA256 = 4; /* String value: "sha256" */ const short SHA384 = 5; /* String value: "sha384" */ const short SHA512 = 6; /* String value: "sha512" */ + const short SHA224 = 7; /* String value: "sha224" */ /** * Initialize the hashing object. This method may be diff --git a/netwerk/protocol/http/nsHttpHandler.cpp b/netwerk/protocol/http/nsHttpHandler.cpp index 1ddffabffc..67e29a0294 100644 --- a/netwerk/protocol/http/nsHttpHandler.cpp +++ b/netwerk/protocol/http/nsHttpHandler.cpp @@ -199,8 +199,9 @@ nsHttpHandler::nsHttpHandler() , mSessionStartTime(0) , mLegacyAppName("Mozilla") , mLegacyAppVersion("5.0") - , mProduct("Gecko") + , mProduct("Goanna") , mCompatFirefoxEnabled(false) + , mCompatFirefoxVersion("52.9") , mUserAgentIsDirty(true) , mPromptTempRedirect(true) , mEnablePersistentHttpsCaching(false) @@ -316,9 +317,13 @@ nsHttpHandler::Init() nsHttpChannelAuthProvider::InitializePrefs(); - mMisc.AssignLiteral("rv:" MOZILLA_UAVERSION); + // rv: should have the Firefox/Gecko compatversion for web compatibility + mMisc.AssignLiteral("rv:"); + mMisc += mCompatFirefoxVersion; - mCompatFirefox.AssignLiteral("Firefox/" MOZILLA_UAVERSION); + mCompatGecko.AssignLiteral("Gecko/20100101"); + mCompatFirefox.AssignLiteral("Firefox/"); + mCompatFirefox += mCompatFirefoxVersion; nsCOMPtr<nsIXULAppInfo> appInfo = do_GetService("@mozilla.org/xre/app-info;1"); @@ -330,12 +335,30 @@ nsHttpHandler::Init() if (mAppName.Length() == 0) { appInfo->GetName(mAppName); } - appInfo->GetVersion(mAppVersion); mAppName.StripChars(R"( ()<>@,;:\"/[]?={})"); + } + + nsCString dynamicBuildID; + if (appInfo) { + appInfo->GetPlatformBuildID(dynamicBuildID); + if (dynamicBuildID.Length() > 8 ) + dynamicBuildID.Left(dynamicBuildID, 8); + } + + if (mAppVersionIsBuildID) { + // Override BuildID + mAppVersion.AssignLiteral(MOZ_UA_BUILDID); + } else if (appInfo) { + appInfo->GetVersion(mAppVersion); } else { - mAppVersion.AssignLiteral(MOZ_APP_UA_VERSION); + // Fall back to platform if appInfo is unavailable + mAppVersion.AssignLiteral(MOZILLA_UAVERSION); } + // If there's no override set, set it to the dynamic BuildID + if (mAppVersion.IsEmpty()) + mAppVersion.Assign(dynamicBuildID); + mSessionStartTime = NowInSeconds(); mHandlerActive = true; @@ -351,11 +374,11 @@ nsHttpHandler::Init() mRequestContextService = do_GetService("@mozilla.org/network/request-context-service;1"); -#if defined(ANDROID) || defined(MOZ_MULET) + // Goanna slice version mProductSub.AssignLiteral(MOZILLA_UAVERSION); -#else - mProductSub.AssignLiteral("20100101"); -#endif + + if (mProductSub.IsEmpty()) + mProductSub.Assign(dynamicBuildID); #if DEBUG // dump user agent prefs @@ -369,6 +392,7 @@ nsHttpHandler::Init() LOG(("> app-name = %s\n", mAppName.get())); LOG(("> app-version = %s\n", mAppVersion.get())); LOG(("> compat-firefox = %s\n", mCompatFirefox.get())); + LOG(("> compat-gecko = %s\n", mCompatGecko.get())); LOG(("> user-agent = %s\n", UserAgent().get())); #endif @@ -678,9 +702,10 @@ nsHttpHandler::BuildUserAgent() mAppName.Length() + mAppVersion.Length() + mCompatFirefox.Length() + + mCompatGecko.Length() + mCompatDevice.Length() + mDeviceModelId.Length() + - 13); + 14); // Application portion mUserAgent.Assign(mLegacyAppName); @@ -710,6 +735,12 @@ nsHttpHandler::BuildUserAgent() } mUserAgent += mMisc; mUserAgent += ')'; + + if(mCompatGeckoEnabled) { + // Provide frozen Gecko/20100101 slice + mUserAgent += ' '; + mUserAgent += mCompatGecko; + } // Product portion mUserAgent += ' '; @@ -719,7 +750,7 @@ nsHttpHandler::BuildUserAgent() bool isFirefox = mAppName.EqualsLiteral("Firefox"); if (isFirefox || mCompatFirefoxEnabled) { - // "Firefox/x.y" (compatibility) app token + // Provide "Firefox/x.y" (compatibility) app token mUserAgent += ' '; mUserAgent += mCompatFirefox; } @@ -966,16 +997,44 @@ nsHttpHandler::PrefsChanged(nsIPrefBranch *prefs, const char *pref) bool cVar = false; + if (PREF_CHANGED(UA_PREF("appVersionIsBuildID"))) { + rv = prefs->GetBoolPref(UA_PREF("appVersionIsBuildID"), &cVar); + mAppVersionIsBuildID = (NS_SUCCEEDED(rv) && cVar); + mUserAgentIsDirty = true; + } + + if (PREF_CHANGED(UA_PREF("compatMode.gecko"))) { + rv = prefs->GetBoolPref(UA_PREF("compatMode.gecko"), &cVar); + mCompatGeckoEnabled = (NS_SUCCEEDED(rv) && cVar); + mUserAgentIsDirty = true; + } + if (PREF_CHANGED(UA_PREF("compatMode.firefox"))) { rv = prefs->GetBoolPref(UA_PREF("compatMode.firefox"), &cVar); mCompatFirefoxEnabled = (NS_SUCCEEDED(rv) && cVar); mUserAgentIsDirty = true; } + // general.useragent.compatMode.version + // This is the version number used in rv: for Gecko compatibility + // and in the Firefox/nn.nn slice when compatMode.firefox is enabled. + if (PREF_CHANGED(UA_PREF("compatMode.version"))) { + prefs->GetCharPref(UA_PREF("compatMode.version"), + getter_Copies(mCompatFirefoxVersion)); + + // rebuild mMisc and compatMode slice + mMisc.AssignLiteral("rv:"); + mMisc += mCompatFirefoxVersion; + mCompatFirefox.AssignLiteral("Firefox/"); + mCompatFirefox += mCompatFirefoxVersion; + + mUserAgentIsDirty = true; + } + // general.useragent.override if (PREF_CHANGED(UA_PREF("override"))) { prefs->GetCharPref(UA_PREF("override"), - getter_Copies(mUserAgentOverride)); + getter_Copies(mUserAgentOverride)); mUserAgentIsDirty = true; } diff --git a/netwerk/protocol/http/nsHttpHandler.h b/netwerk/protocol/http/nsHttpHandler.h index 13cc72e8ef..d51662db90 100644 --- a/netwerk/protocol/http/nsHttpHandler.h +++ b/netwerk/protocol/http/nsHttpHandler.h @@ -485,7 +485,11 @@ private: nsXPIDLCString mProductSub; nsXPIDLCString mAppName; nsXPIDLCString mAppVersion; + bool mAppVersionIsBuildID; + nsCString mCompatGecko; + bool mCompatGeckoEnabled; nsCString mCompatFirefox; + nsCString mCompatFirefoxVersion; bool mCompatFirefoxEnabled; nsXPIDLCString mCompatDevice; nsCString mDeviceModelId; diff --git a/old-configure.in b/old-configure.in index 92a5f729e4..afa6e30691 100644 --- a/old-configure.in +++ b/old-configure.in @@ -3210,15 +3210,20 @@ dnl ================================== dnl = Check alsa availability on Linux dnl ================================== +dnl If using Linux, enable the alsa library by default +if test "$OS_TARGET" = "Linux"; then + MOZ_ALSA=1 +fi + MOZ_ARG_ENABLE_BOOL(alsa, -[ --enable-alsa Enable Alsa support], +[ --enable-alsa Enable Alsa support (default on Linux)], MOZ_ALSA=1, MOZ_ALSA=) if test -n "$MOZ_ALSA"; then PKG_CHECK_MODULES(MOZ_ALSA, alsa, , [echo "$MOZ_ALSA_PKG_ERRORS" - AC_MSG_ERROR([Need alsa for audio output on Linux. (On Ubuntu, you might try installing the package libasound2-dev.)])]) + AC_MSG_ERROR([You need ALSA for audio output on Linux.])]) fi AC_SUBST(MOZ_ALSA) @@ -3246,7 +3251,7 @@ if test -n "$MOZ_PULSEAUDIO"; then if test -z "$gonkdir"; then PKG_CHECK_MODULES(MOZ_PULSEAUDIO, libpulse, , [echo "$MOZ_PULSEAUDIO_PKG_ERRORS" - AC_MSG_ERROR([pulseaudio audio backend requires libpulse development package])]) + AC_MSG_ERROR([Building pulseaudio audio backend requires libpulse development package])]) else MOZ_PULSEAUDIO_CFLAGS="-I$gonkdir/external/pulseaudio/pulseaudio/src" fi @@ -5459,6 +5464,9 @@ fi AC_SUBST(MOZ_APP_STATIC_INI) +AC_DEFINE_UNQUOTED(MOZ_UA_BUILDID, "$MOZ_UA_BUILDID") +AC_SUBST(MOZ_UA_BUILDID) + AC_SUBST(MOZ_PKG_SPECIAL) AC_SUBST(MOZ_SIMPLE_PACKAGE_NAME) diff --git a/python/mozbuild/mozbuild/milestone.py b/python/mozbuild/mozbuild/milestone.py index c2aa78fcd9..3ef55d540d 100644 --- a/python/mozbuild/mozbuild/milestone.py +++ b/python/mozbuild/mozbuild/milestone.py @@ -43,6 +43,12 @@ def get_milestone_major(milestone): return milestone.split('.')[0] +def get_milestone_minor(milestone): + """ + Returns the minor (second) part of the milestone. + """ + + return milestone.split('.')[1] def main(args): parser = argparse.ArgumentParser() @@ -56,9 +62,9 @@ def main(args): milestone = get_official_milestone(milestone_file) if options.uaversion: - # Only expose the major milestone in the UA string, hide the patch - # level (bugs 572659 and 870868). - uaversion = "%s.0" % (get_milestone_major(milestone),) + # Only expose the major+minor milestone in the UA string. + uaversion = "%s.%s" % (get_milestone_major(milestone), + get_milestone_minor(milestone)) print(uaversion) elif options.symbolversion: diff --git a/services/crypto/modules/utils.js b/services/crypto/modules/utils.js index c17f5dfa18..e3a77ad0a0 100644 --- a/services/crypto/modules/utils.js +++ b/services/crypto/modules/utils.js @@ -77,43 +77,6 @@ this.CryptoUtils = { }, /** - * UTF-8 encode a message and perform a SHA-1 over it. - * - * @param message - * (string) Buffer to perform operation on. Should be a JS string. - * It is possible to pass in a string representing an array - * of bytes. But, you probably don't want to UTF-8 encode - * such data and thus should not be using this function. - * - * @return string - * Raw bytes constituting SHA-1 hash. Value is a JS string. Each - * character is the byte value for that offset. Returned string - * always has .length == 20. - */ - UTF8AndSHA1: function UTF8AndSHA1(message) { - let hasher = Cc["@mozilla.org/security/hash;1"] - .createInstance(Ci.nsICryptoHash); - hasher.init(hasher.SHA1); - - return CryptoUtils.digestUTF8(message, hasher); - }, - - sha1: function sha1(message) { - return CommonUtils.bytesAsHex(CryptoUtils.UTF8AndSHA1(message)); - }, - - sha1Base32: function sha1Base32(message) { - return CommonUtils.encodeBase32(CryptoUtils.UTF8AndSHA1(message)); - }, - - sha256(message) { - let hasher = Cc["@mozilla.org/security/hash;1"] - .createInstance(Ci.nsICryptoHash); - hasher.init(hasher.SHA256); - return CommonUtils.bytesAsHex(CryptoUtils.digestUTF8(message, hasher)); - }, - - /** * Produce an HMAC key object from a key string. */ makeHMACKey: function makeHMACKey(str) { @@ -187,9 +150,8 @@ this.CryptoUtils = { hmacAlg=Ci.nsICryptoHMAC.SHA1, hmacLen=20) { // We don't have a default in the algo itself, as NSS does. - // Use the constant. if (!dkLen) { - dkLen = SYNC_KEY_DECODED_LENGTH; + throw new Error("dkLen should be defined"); } function F(S, c, i, h) { @@ -551,6 +513,48 @@ this.CryptoUtils = { }; +/** + * Hashing Algorithms SHA-X. + * These values map directly onto the values defined + * in netwerk/base/nsICryptoHash.idl. + */ +let shaX = ["1", "256", "384", "512", "224"]; + +for (let shaIdx = 0, shaIdxLen = shaX.length; shaIdx < shaIdxLen; shaIdx++) { + let shaXIdx = shaX[shaIdx]; + + /** + * UTF-8 encode a message and perform a SHA-X over it. + * + * @param message + * (string) Buffer to perform operation on. Should be a JS string. + * It is possible to pass in a string representing an array + * of bytes. But, you probably don't want to UTF-8 encode + * such data and thus should not be using this function. + * + * @return string + * Raw bytes constituting SHA-X hash. Value is a JS string. + * Each character is the byte value for that offset. + */ + CryptoUtils["UTF8AndSHA" + shaXIdx] = function (message) { + let hasher = Cc["@mozilla.org/security/hash;1"] + .createInstance(Ci.nsICryptoHash); + hasher.init(hasher["SHA" + shaXIdx]); + + return CryptoUtils.digestUTF8(message, hasher); + }; + + CryptoUtils["sha" + shaXIdx] = function (message) { + return CommonUtils.bytesAsHex( + CryptoUtils["UTF8AndSHA" + shaXIdx](message)); + }; + + CryptoUtils["sha" + shaXIdx + "Base32"] = function (message) { + return CommonUtils.encodeBase32( + CryptoUtils["UTF8AndSHA" + shaXIdx](message)); + }; +} + XPCOMUtils.defineLazyGetter(CryptoUtils, "_utf8Converter", function() { let converter = Cc["@mozilla.org/intl/scriptableunicodeconverter"] .createInstance(Ci.nsIScriptableUnicodeConverter); diff --git a/toolkit/components/alerts/resources/content/alert.js b/toolkit/components/alerts/resources/content/alert.js index 523ec378e7..ead4d503f8 100644 --- a/toolkit/components/alerts/resources/content/alert.js +++ b/toolkit/components/alerts/resources/content/alert.js @@ -7,7 +7,21 @@ var {classes: Cc, interfaces: Ci, utils: Cu, results: Cr} = Components; Cu.import("resource://gre/modules/AppConstants.jsm"); Cu.import("resource://gre/modules/Services.jsm"); -// Copied from nsILookAndFeel.h, see comments on eMetric_AlertNotificationOrigin +/* + * This indicates from which corner of the screen alerts slide in, + * and from which direction (horizontal/vertical). + * 0, the default, represents bottom right, sliding vertically. + * Use any bitwise combination of the following constants: + * NS_ALERT_HORIZONTAL (1), NS_ALERT_LEFT (2), NS_ALERT_TOP (4). + * + * 6 4 + * +-----------+ + * 7| |5 + * | | + * 3| |1 + * +-----------+ + * 2 0 + */ const NS_ALERT_HORIZONTAL = 1; const NS_ALERT_LEFT = 2; const NS_ALERT_TOP = 4; @@ -41,6 +55,8 @@ function prefillAlertInfo() { // arguments[11] -> the nsIURI.hostPort of the origin, optional // arguments[12] -> the alert icon URL, optional + document.getElementById('alertTime').setAttribute('value', (new Date).getTime()); + switch (window.arguments.length) { default: case 13: { @@ -235,7 +251,15 @@ function moveWindowToEnd() { let windows = Services.wm.getEnumerator("alert:alert"); while (windows.hasMoreElements()) { let alertWindow = windows.getNext(); - if (alertWindow != window) { + let alertWindowTime = Number( + alertWindow.document.getElementById('alertTime').getAttribute('value')); + let windowTime = Number( + window.document.getElementById('alertTime').getAttribute('value')); + // The time of window creation. + // Otherwise calling the notification twice (and more) in a row + // does not work. + // See https://bugzilla.mozilla.org/show_bug.cgi?id=1263155 + if ((alertWindow != window) && (alertWindowTime <= windowTime)) { if (gOrigin & NS_ALERT_TOP) { y = Math.max(y, alertWindow.screenY + alertWindow.outerHeight - WINDOW_SHADOW_SPREAD); } else { diff --git a/toolkit/components/alerts/resources/content/alert.xul b/toolkit/components/alerts/resources/content/alert.xul index 8597d9954d..1549f45302 100644 --- a/toolkit/components/alerts/resources/content/alert.xul +++ b/toolkit/components/alerts/resources/content/alert.xul @@ -24,6 +24,7 @@ <script type="application/javascript" src="chrome://global/content/alerts/alert.js"/> <vbox id="alertBox" class="alertBox"> + <label id="alertTime" value="" hidden="true"/> <box id="alertTitleBox"> <image id="alertIcon"/> <label id="alertTitleLabel" class="alertTitle plain" crop="end"/> diff --git a/toolkit/content/mozilla.xhtml b/toolkit/content/mozilla.xhtml index 1ffde19e43..2acfc9f5d0 100644 --- a/toolkit/content/mozilla.xhtml +++ b/toolkit/content/mozilla.xhtml @@ -13,7 +13,7 @@ <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta charset='utf-8' /> - <title>&mozilla.title.15.1;</title> + <title>&chronicles.title.55.2;</title> <style> html { @@ -54,11 +54,11 @@ a { <section> <p id="moztext"> - &mozilla.quote.15.1; + &chronicles.quote.55.2; </p> <p id="from"> - &mozilla.from.15.1; + &chronicles.from.55.2; </p> </section> diff --git a/toolkit/locales/en-US/chrome/global/mozilla.dtd b/toolkit/locales/en-US/chrome/global/mozilla.dtd index 74ae40d449..038d8eb757 100644 --- a/toolkit/locales/en-US/chrome/global/mozilla.dtd +++ b/toolkit/locales/en-US/chrome/global/mozilla.dtd @@ -2,13 +2,13 @@ - License, v. 2.0. If a copy of the MPL was not distributed with this - file, You can obtain one at http://mozilla.org/MPL/2.0/. --> -<!ENTITY mozilla.title.15.1 -'The Book of Mozilla, 15:1'> +<!ENTITY chronicles.title.55.2 +'The Chronicles of the Pale Moon, 55:2'> -<!ENTITY mozilla.quote.15.1 -'The <em>twins</em> of Mammon quarrelled. Their warring plunged the world into a <em>new darkness</em>, and the beast -abhorred the darkness. So it began to move <em>swiftly</em>, and grew more powerful, and went forth and multiplied. -And the beasts brought <em>fire</em> and light to the darkness.'> +<!ENTITY chronicles.quote.55.2 +'And so, our focus was drawn through time and space to the <em>emerging dragon</em> who would not abandon hope.<br/> +Its resilience, stubbornness and spirit unbroken, and searching for long hours to find those willing to <em>join</em> its cause.<br/> +The old nest abandoned, the death throes of the Beast ignored, and more determined than ever to find glory in the future.'> -<!ENTITY mozilla.from.15.1 -'from <strong>The Book of Mozilla,</strong> 15:1'> +<!ENTITY chronicles.from.55.2 +'from <strong>The Chronicles of the Pale Moon,</strong> 55:2'> diff --git a/toolkit/themes/windows/global/dirListing/folder-XP.png b/toolkit/themes/windows/global/dirListing/folder-XP.png Binary files differdeleted file mode 100644 index 102de51960..0000000000 --- a/toolkit/themes/windows/global/dirListing/folder-XP.png +++ /dev/null diff --git a/toolkit/themes/windows/global/dirListing/local-XP.png b/toolkit/themes/windows/global/dirListing/local-XP.png Binary files differdeleted file mode 100644 index 99191f3a52..0000000000 --- a/toolkit/themes/windows/global/dirListing/local-XP.png +++ /dev/null diff --git a/toolkit/themes/windows/global/dirListing/remote-XP.png b/toolkit/themes/windows/global/dirListing/remote-XP.png Binary files differdeleted file mode 100644 index 4febb764bd..0000000000 --- a/toolkit/themes/windows/global/dirListing/remote-XP.png +++ /dev/null diff --git a/toolkit/themes/windows/global/dirListing/up-XP.png b/toolkit/themes/windows/global/dirListing/up-XP.png Binary files differdeleted file mode 100644 index 851502d47d..0000000000 --- a/toolkit/themes/windows/global/dirListing/up-XP.png +++ /dev/null diff --git a/toolkit/themes/windows/global/global.css b/toolkit/themes/windows/global/global.css index 20a190684b..aaddef882d 100644 --- a/toolkit/themes/windows/global/global.css +++ b/toolkit/themes/windows/global/global.css @@ -350,9 +350,7 @@ popupnotificationcontent { width: 20px; } -@media (-moz-os-version: windows-xp), - (-moz-os-version: windows-vista), - (-moz-os-version: windows-win7) { +@media (-moz-os-version: windows-win7) { .close-icon { -moz-image-region: rect(0, 16px, 16px, 0); } @@ -386,9 +384,7 @@ popupnotificationcontent { -moz-image-region: rect(0, 120px, 40px, 80px); } - @media (-moz-os-version: windows-xp), - (-moz-os-version: windows-vista), - (-moz-os-version: windows-win7) { + @media (-moz-os-version: windows-win7) { .close-icon { -moz-image-region: rect(0, 32px, 32px, 0); } diff --git a/toolkit/themes/windows/global/icons/Landscape-XP.png b/toolkit/themes/windows/global/icons/Landscape-XP.png Binary files differdeleted file mode 100644 index cc43abdf31..0000000000 --- a/toolkit/themes/windows/global/icons/Landscape-XP.png +++ /dev/null diff --git a/toolkit/themes/windows/global/icons/Portrait-XP.png b/toolkit/themes/windows/global/icons/Portrait-XP.png Binary files differdeleted file mode 100644 index ce36e84132..0000000000 --- a/toolkit/themes/windows/global/icons/Portrait-XP.png +++ /dev/null diff --git a/toolkit/themes/windows/global/icons/Print-preview-XP.png b/toolkit/themes/windows/global/icons/Print-preview-XP.png Binary files differdeleted file mode 100644 index 6f4736737f..0000000000 --- a/toolkit/themes/windows/global/icons/Print-preview-XP.png +++ /dev/null diff --git a/toolkit/themes/windows/global/icons/Question-XP.png b/toolkit/themes/windows/global/icons/Question-XP.png Binary files differdeleted file mode 100644 index c10004078b..0000000000 --- a/toolkit/themes/windows/global/icons/Question-XP.png +++ /dev/null diff --git a/toolkit/themes/windows/global/icons/Search-close-XP.png b/toolkit/themes/windows/global/icons/Search-close-XP.png Binary files differdeleted file mode 100644 index 39d800e1ae..0000000000 --- a/toolkit/themes/windows/global/icons/Search-close-XP.png +++ /dev/null diff --git a/toolkit/themes/windows/global/icons/Search-glass-XP.png b/toolkit/themes/windows/global/icons/Search-glass-XP.png Binary files differdeleted file mode 100644 index 9eb0e259f2..0000000000 --- a/toolkit/themes/windows/global/icons/Search-glass-XP.png +++ /dev/null diff --git a/toolkit/themes/windows/global/icons/Warning-XP.png b/toolkit/themes/windows/global/icons/Warning-XP.png Binary files differdeleted file mode 100644 index c0ec9b519f..0000000000 --- a/toolkit/themes/windows/global/icons/Warning-XP.png +++ /dev/null diff --git a/toolkit/themes/windows/global/icons/autoscroll-XP.png b/toolkit/themes/windows/global/icons/autoscroll-XP.png Binary files differdeleted file mode 100644 index 6aac3d98e9..0000000000 --- a/toolkit/themes/windows/global/icons/autoscroll-XP.png +++ /dev/null diff --git a/toolkit/themes/windows/global/icons/blacklist_favicon-XP.png b/toolkit/themes/windows/global/icons/blacklist_favicon-XP.png Binary files differdeleted file mode 100644 index 74af56f577..0000000000 --- a/toolkit/themes/windows/global/icons/blacklist_favicon-XP.png +++ /dev/null diff --git a/toolkit/themes/windows/global/icons/blacklist_large-XP.png b/toolkit/themes/windows/global/icons/blacklist_large-XP.png Binary files differdeleted file mode 100644 index 96ff341c0a..0000000000 --- a/toolkit/themes/windows/global/icons/blacklist_large-XP.png +++ /dev/null diff --git a/toolkit/themes/windows/global/icons/close-inverted-XPVista7.png b/toolkit/themes/windows/global/icons/close-inverted-win7.png Binary files differindex 68596a3076..68596a3076 100644 --- a/toolkit/themes/windows/global/icons/close-inverted-XPVista7.png +++ b/toolkit/themes/windows/global/icons/close-inverted-win7.png diff --git a/toolkit/themes/windows/global/icons/close-inverted-XPVista7@2x.png b/toolkit/themes/windows/global/icons/close-inverted-win7@2x.png Binary files differindex eec52e6d13..eec52e6d13 100644 --- a/toolkit/themes/windows/global/icons/close-inverted-XPVista7@2x.png +++ b/toolkit/themes/windows/global/icons/close-inverted-win7@2x.png diff --git a/toolkit/themes/windows/global/icons/close-XPVista7.png b/toolkit/themes/windows/global/icons/close-win7.png Binary files differindex ea6ada49e6..ea6ada49e6 100644 --- a/toolkit/themes/windows/global/icons/close-XPVista7.png +++ b/toolkit/themes/windows/global/icons/close-win7.png diff --git a/toolkit/themes/windows/global/icons/close-XPVista7@2x.png b/toolkit/themes/windows/global/icons/close-win7@2x.png Binary files differindex c25a64a4b0..c25a64a4b0 100644 --- a/toolkit/themes/windows/global/icons/close-XPVista7@2x.png +++ b/toolkit/themes/windows/global/icons/close-win7@2x.png diff --git a/toolkit/themes/windows/global/icons/error-16-XP.png b/toolkit/themes/windows/global/icons/error-16-XP.png Binary files differdeleted file mode 100644 index 936d2abeb9..0000000000 --- a/toolkit/themes/windows/global/icons/error-16-XP.png +++ /dev/null diff --git a/toolkit/themes/windows/global/icons/error-64-XP.png b/toolkit/themes/windows/global/icons/error-64-XP.png Binary files differdeleted file mode 100644 index 75a00c4903..0000000000 --- a/toolkit/themes/windows/global/icons/error-64-XP.png +++ /dev/null diff --git a/toolkit/themes/windows/global/icons/folder-item-XP.png b/toolkit/themes/windows/global/icons/folder-item-XP.png Binary files differdeleted file mode 100644 index 26cda98c9b..0000000000 --- a/toolkit/themes/windows/global/icons/folder-item-XP.png +++ /dev/null diff --git a/toolkit/themes/windows/global/icons/information-16-XP.png b/toolkit/themes/windows/global/icons/information-16-XP.png Binary files differdeleted file mode 100644 index aa8ce6e88a..0000000000 --- a/toolkit/themes/windows/global/icons/information-16-XP.png +++ /dev/null diff --git a/toolkit/themes/windows/global/icons/information-24-XP.png b/toolkit/themes/windows/global/icons/information-24-XP.png Binary files differdeleted file mode 100644 index 7fa782d58c..0000000000 --- a/toolkit/themes/windows/global/icons/information-24-XP.png +++ /dev/null diff --git a/toolkit/themes/windows/global/icons/information-32-XP.png b/toolkit/themes/windows/global/icons/information-32-XP.png Binary files differdeleted file mode 100644 index 5120db685e..0000000000 --- a/toolkit/themes/windows/global/icons/information-32-XP.png +++ /dev/null diff --git a/toolkit/themes/windows/global/icons/question-16-XP.png b/toolkit/themes/windows/global/icons/question-16-XP.png Binary files differdeleted file mode 100644 index 0c8eafda08..0000000000 --- a/toolkit/themes/windows/global/icons/question-16-XP.png +++ /dev/null diff --git a/toolkit/themes/windows/global/icons/question-64-XP.png b/toolkit/themes/windows/global/icons/question-64-XP.png Binary files differdeleted file mode 100644 index a1a51b8d8f..0000000000 --- a/toolkit/themes/windows/global/icons/question-64-XP.png +++ /dev/null diff --git a/toolkit/themes/windows/global/icons/sslWarning-XP.png b/toolkit/themes/windows/global/icons/sslWarning-XP.png Binary files differdeleted file mode 100644 index 09946986fe..0000000000 --- a/toolkit/themes/windows/global/icons/sslWarning-XP.png +++ /dev/null diff --git a/toolkit/themes/windows/global/icons/warning-16-XP.png b/toolkit/themes/windows/global/icons/warning-16-XP.png Binary files differdeleted file mode 100644 index a21574370b..0000000000 --- a/toolkit/themes/windows/global/icons/warning-16-XP.png +++ /dev/null diff --git a/toolkit/themes/windows/global/icons/warning-64-XP.png b/toolkit/themes/windows/global/icons/warning-64-XP.png Binary files differdeleted file mode 100644 index 832f348867..0000000000 --- a/toolkit/themes/windows/global/icons/warning-64-XP.png +++ /dev/null diff --git a/toolkit/themes/windows/global/icons/warning-large-XP.png b/toolkit/themes/windows/global/icons/warning-large-XP.png Binary files differdeleted file mode 100644 index 0ec8e79f68..0000000000 --- a/toolkit/themes/windows/global/icons/warning-large-XP.png +++ /dev/null diff --git a/toolkit/themes/windows/global/icons/windowControls-XP.png b/toolkit/themes/windows/global/icons/windowControls-XP.png Binary files differdeleted file mode 100644 index d90efb05b2..0000000000 --- a/toolkit/themes/windows/global/icons/windowControls-XP.png +++ /dev/null diff --git a/toolkit/themes/windows/global/jar.mn b/toolkit/themes/windows/global/jar.mn index 7f07710204..7f2f29942f 100644 --- a/toolkit/themes/windows/global/jar.mn +++ b/toolkit/themes/windows/global/jar.mn @@ -44,102 +44,36 @@ toolkit.jar: skin/classic/global/icons/autocomplete-search.svg (icons/autocomplete-search.svg) skin/classic/global/icons/blacklist_favicon.png (icons/blacklist_favicon.png) skin/classic/global/icons/blacklist_large.png (icons/blacklist_large.png) - skin/classic/global/icons/close-XPVista7.png (icons/close-XPVista7.png) - skin/classic/global/icons/close-XPVista7@2x.png (icons/close-XPVista7@2x.png) - skin/classic/global/icons/close-inverted-XPVista7.png (icons/close-inverted-XPVista7.png) - skin/classic/global/icons/close-inverted-XPVista7@2x.png (icons/close-inverted-XPVista7@2x.png) + skin/classic/global/icons/close-win7.png (icons/close-win7.png) + skin/classic/global/icons/close-win7@2x.png (icons/close-win7@2x.png) + skin/classic/global/icons/close-inverted-win7.png (icons/close-inverted-win7.png) + skin/classic/global/icons/close-inverted-win7@2x.png (icons/close-inverted-win7@2x.png) skin/classic/global/icons/resizer.png (icons/resizer.png) skin/classic/global/icons/sslWarning.png (icons/sslWarning.png) * skin/classic/global/in-content/common.css (in-content/common.css) * skin/classic/global/in-content/info-pages.css (in-content/info-pages.css) skin/classic/global/toolbar/spring.png (toolbar/spring.png) - skin/classic/global/dirListing/folder-XP.png (dirListing/folder-XP.png) - skin/classic/global/dirListing/local-XP.png (dirListing/local-XP.png) - skin/classic/global/dirListing/remote-XP.png (dirListing/remote-XP.png) - skin/classic/global/dirListing/up-XP.png (dirListing/up-XP.png) - skin/classic/global/icons/autoscroll.png (icons/autoscroll.png) - skin/classic/global/icons/autoscroll-XP.png (icons/autoscroll-XP.png) - skin/classic/global/icons/blacklist_favicon-XP.png (icons/blacklist_favicon-XP.png) - skin/classic/global/icons/blacklist_large-XP.png (icons/blacklist_large-XP.png) - skin/classic/global/icons/Error-XP.png (icons/Error-XP.png) - skin/classic/global/icons/error-16-XP.png (icons/error-16-XP.png) - skin/classic/global/icons/error-64-XP.png (icons/error-64-XP.png) - skin/classic/global/icons/folder-item-XP.png (icons/folder-item-XP.png) - skin/classic/global/icons/information-16-XP.png (icons/information-16-XP.png) - skin/classic/global/icons/information-24-XP.png (icons/information-24-XP.png) - skin/classic/global/icons/information-32-XP.png (icons/information-32-XP.png) - skin/classic/global/icons/Print-preview-XP.png (icons/Print-preview-XP.png) - skin/classic/global/icons/Portrait-XP.png (icons/Portrait-XP.png) - skin/classic/global/icons/Landscape-XP.png (icons/Landscape-XP.png) - skin/classic/global/icons/Question-XP.png (icons/Question-XP.png) - skin/classic/global/icons/question-16-XP.png (icons/question-16-XP.png) - skin/classic/global/icons/question-64-XP.png (icons/question-64-XP.png) - skin/classic/global/icons/Search-close-XP.png (icons/Search-close-XP.png) - skin/classic/global/icons/Search-glass-XP.png (icons/Search-glass-XP.png) - skin/classic/global/icons/sslWarning-XP.png (icons/sslWarning-XP.png) - skin/classic/global/icons/Warning-XP.png (icons/Warning-XP.png) - skin/classic/global/icons/warning-large-XP.png (icons/warning-large-XP.png) - skin/classic/global/icons/warning-16-XP.png (icons/warning-16-XP.png) - skin/classic/global/icons/warning-64-XP.png (icons/warning-64-XP.png) - skin/classic/global/icons/windowControls-XP.png (icons/windowControls-XP.png) - skin/classic/global/toolbar/spring-XP.png (toolbar/spring-XP.png) - skin/classic/global/tree/sort-asc-XP.png (tree/sort-asc-XP.png) - skin/classic/global/tree/sort-dsc-XP.png (tree/sort-dsc-XP.png) - skin/classic/global/tree/twisty.svg (tree/twisty.svg) - skin/classic/global/tree/twisty-XP.svg (tree/twisty-XP.svg) - skin/classic/global/tree/twisty-Vista78.svg (tree/twisty-Vista78.svg) + skin/classic/global/icons/autoscroll.png (icons/autoscroll.png) + skin/classic/global/tree/twisty.svg (tree/twisty.svg) + skin/classic/global/tree/twisty-preWin10.svg (tree/twisty-preWin10.svg) #ifdef MOZ_PHOENIX [browser/extensions/{972ce4c6-7e08-4474-a285-3208198ce6fd}] chrome.jar: #elif MOZ_SEPARATE_MANIFEST_FOR_THEME_OVERRIDES [extensions/{972ce4c6-7e08-4474-a285-3208198ce6fd}] chrome.jar: #endif -% override chrome://global/skin/dirListing/folder.png chrome://global/skin/dirListing/folder-XP.png osversion<6 -% override chrome://global/skin/dirListing/local.png chrome://global/skin/dirListing/local-XP.png osversion<6 -% override chrome://global/skin/dirListing/remote.png chrome://global/skin/dirListing/remote-XP.png osversion<6 -% override chrome://global/skin/dirListing/up.png chrome://global/skin/dirListing/up-XP.png osversion<6 -% override chrome://global/skin/icons/autoscroll.png chrome://global/skin/icons/autoscroll-XP.png osversion<6 -% override chrome://global/skin/icons/blacklist_favicon.png chrome://global/skin/icons/blacklist_favicon-XP.png osversion<6 -% override chrome://global/skin/icons/blacklist_large.png chrome://global/skin/icons/blacklist_large-XP.png osversion<6 -% override chrome://global/skin/icons/Error.png chrome://global/skin/icons/Error-XP.png osversion<6 -% override chrome://global/skin/icons/error-16.png chrome://global/skin/icons/error-16-XP.png osversion<6 -% override chrome://global/skin/icons/error-64.png chrome://global/skin/icons/error-64-XP.png osversion<6 -% override chrome://global/skin/icons/folder-item.png chrome://global/skin/icons/folder-item-XP.png osversion<6 -% override chrome://global/skin/icons/information-16.png chrome://global/skin/icons/information-16-XP.png osversion<6 -% override chrome://global/skin/icons/information-24.png chrome://global/skin/icons/information-24-XP.png osversion<6 -% override chrome://global/skin/icons/information-32.png chrome://global/skin/icons/information-32-XP.png osversion<6 -% override chrome://global/skin/icons/Print-preview.png chrome://global/skin/icons/Print-preview-XP.png osversion<6 -% override chrome://global/skin/icons/Portrait.png chrome://global/skin/icons/Portrait-XP.png osversion<6 -% override chrome://global/skin/icons/Landscape.png chrome://global/skin/icons/Landscape-XP.png osversion<6 -% override chrome://global/skin/icons/Question.png chrome://global/skin/icons/Question-XP.png osversion<6 -% override chrome://global/skin/icons/question-16.png chrome://global/skin/icons/question-16-XP.png osversion<6 -% override chrome://global/skin/icons/question-64.png chrome://global/skin/icons/question-64-XP.png osversion<6 -% override chrome://global/skin/icons/Search-close.png chrome://global/skin/icons/Search-close-XP.png osversion<6 -% override chrome://global/skin/icons/Search-glass.png chrome://global/skin/icons/Search-glass-XP.png osversion<6 -% override chrome://global/skin/icons/sslWarning.png chrome://global/skin/icons/sslWarning-XP.png osversion<6 -% override chrome://global/skin/icons/Warning.png chrome://global/skin/icons/Warning-XP.png osversion<6 -% override chrome://global/skin/icons/warning-large.png chrome://global/skin/icons/warning-large-XP.png osversion<6 -% override chrome://global/skin/icons/warning-16.png chrome://global/skin/icons/warning-16-XP.png osversion<6 -% override chrome://global/skin/icons/warning-64.png chrome://global/skin/icons/warning-64-XP.png osversion<6 -% override chrome://global/skin/icons/windowControls.png chrome://global/skin/icons/windowControls-XP.png osversion<6 -% override chrome://global/skin/toolbar/spring.png chrome://global/skin/toolbar/spring-XP.png osversion<6 -% override chrome://global/skin/tree/sort-asc.png chrome://global/skin/tree/sort-asc-XP.png osversion<6 -% override chrome://global/skin/tree/sort-dsc.png chrome://global/skin/tree/sort-dsc-XP.png osversion<6 -% override chrome://global/skin/icons/close.png chrome://global/skin/icons/close-XPVista7.png osversion<=6.1 -% override chrome://global/skin/icons/close@2x.png chrome://global/skin/icons/close-XPVista7@2x.png osversion<=6.1 -% override chrome://global/skin/icons/close-inverted.png chrome://global/skin/icons/close-inverted-XPVista7.png osversion<=6.1 -% override chrome://global/skin/icons/close-inverted@2x.png chrome://global/skin/icons/close-inverted-XPVista7@2x.png osversion<=6.1 +% override chrome://global/skin/icons/close.png chrome://global/skin/icons/close-win7.png osversion<=6.1 +% override chrome://global/skin/icons/close@2x.png chrome://global/skin/icons/close-win7@2x.png osversion<=6.1 +% override chrome://global/skin/icons/close-inverted.png chrome://global/skin/icons/close-inverted-win7.png osversion<=6.1 +% override chrome://global/skin/icons/close-inverted@2x.png chrome://global/skin/icons/close-inverted-win7@2x.png osversion<=6.1 -% override chrome://global/skin/tree/twisty.svg#clsd chrome://global/skin/tree/twisty-Vista78.svg#clsd osversion<=6.3 -% override chrome://global/skin/tree/twisty.svg#clsd-rtl chrome://global/skin/tree/twisty-Vista78.svg#clsd-rtl osversion<=6.3 -% override chrome://global/skin/tree/twisty.svg#clsd-hover chrome://global/skin/tree/twisty-Vista78.svg#clsd-hover osversion<=6.3 -% override chrome://global/skin/tree/twisty.svg#clsd-hover-rtl chrome://global/skin/tree/twisty-Vista78.svg#clsd-hover-rtl osversion<=6.3 -% override chrome://global/skin/tree/twisty.svg#open chrome://global/skin/tree/twisty-Vista78.svg#open osversion<=6.3 -% override chrome://global/skin/tree/twisty.svg#open-rtl chrome://global/skin/tree/twisty-Vista78.svg#open-rtl osversion<=6.3 -% override chrome://global/skin/tree/twisty.svg#open-hover chrome://global/skin/tree/twisty-Vista78.svg#open-hover osversion<=6.3 -% override chrome://global/skin/tree/twisty.svg#open-hover-rtl chrome://global/skin/tree/twisty-Vista78.svg#open-hover-rtl osversion<=6.3 -# to be sure osversion<6 has always higher precedence than osversion<=6.3 we override twisty-Vista78.svg instead of twisty.svg -% override chrome://global/skin/tree/twisty-Vista78.svg#clsd chrome://global/skin/tree/twisty-XP.svg#clsd osversion<6 -% override chrome://global/skin/tree/twisty-Vista78.svg#open chrome://global/skin/tree/twisty-XP.svg#open osversion<6 +% override chrome://global/skin/tree/twisty.svg#clsd chrome://global/skin/tree/twisty-preWin10.svg#clsd osversion<=6.3 +% override chrome://global/skin/tree/twisty.svg#clsd-rtl chrome://global/skin/tree/twisty-preWin10.svg#clsd-rtl osversion<=6.3 +% override chrome://global/skin/tree/twisty.svg#clsd-hover chrome://global/skin/tree/twisty-preWin10.svg#clsd-hover osversion<=6.3 +% override chrome://global/skin/tree/twisty.svg#clsd-hover-rtl chrome://global/skin/tree/twisty-preWin10.svg#clsd-hover-rtl osversion<=6.3 +% override chrome://global/skin/tree/twisty.svg#open chrome://global/skin/tree/twisty-preWin10.svg#open osversion<=6.3 +% override chrome://global/skin/tree/twisty.svg#open-rtl chrome://global/skin/tree/twisty-preWin10.svg#open-rtl osversion<=6.3 +% override chrome://global/skin/tree/twisty.svg#open-hover chrome://global/skin/tree/twisty-preWin10.svg#open-hover osversion<=6.3 +% override chrome://global/skin/tree/twisty.svg#open-hover-rtl chrome://global/skin/tree/twisty-preWin10.svg#open-hover-rtl osversion<=6.3 diff --git a/toolkit/themes/windows/global/listbox.css b/toolkit/themes/windows/global/listbox.css index fd60b16934..ddea3f8fa1 100644 --- a/toolkit/themes/windows/global/listbox.css +++ b/toolkit/themes/windows/global/listbox.css @@ -144,70 +144,67 @@ listheader[sortable="true"]:hover:active { } @media (-moz-windows-default-theme) { - @media not all and (-moz-os-version: windows-xp) { - listitem { - --listitem-selectedColor: rgb(217,217,217); - --listitem-selectedBorder: var(--listitem-selectedColor); - --listitem-selectedBottomBorder: rgb(204,204,204); - --listitem-selectedBackground: var(--listitem-selectedColor); - --listitem-selectedImage: none; - --listitem-selectedCurrentBorder: rgb(123,195,255); - --listitem-selectedFocusColor: rgb(205,232,255); - --listitem-selectedFocusBorder: var(--listitem-selectedFocusColor); - --listitem-selectedFocusBottomBorder: rgb(165,214,255); - --listitem-selectedFocusBackground: var(--listitem-selectedFocusColor); - --listitem-selectedFocusImage: none; - --listitem-selectedFocusCurrentBorder: var(--listitem-selectedFocusColor); - --listitem-selectedFocusCurrentBottomBorder: var(--listitem-selectedFocusBottomBorder); - --listitem-selectedFocusCurrentBackground: var(--listitem-selectedFocusColor); - - color: -moz-FieldText; - margin-inline-start: 1px; - margin-inline-end: 1px; - padding-top: 1px; - padding-bottom: 1px; - border-width: 1px; - background-repeat: no-repeat; - background-size: 100% 100%; - } + listitem { + --listitem-selectedColor: rgb(217,217,217); + --listitem-selectedBorder: var(--listitem-selectedColor); + --listitem-selectedBottomBorder: rgb(204,204,204); + --listitem-selectedBackground: var(--listitem-selectedColor); + --listitem-selectedImage: none; + --listitem-selectedCurrentBorder: rgb(123,195,255); + --listitem-selectedFocusColor: rgb(205,232,255); + --listitem-selectedFocusBorder: var(--listitem-selectedFocusColor); + --listitem-selectedFocusBottomBorder: rgb(165,214,255); + --listitem-selectedFocusBackground: var(--listitem-selectedFocusColor); + --listitem-selectedFocusImage: none; + --listitem-selectedFocusCurrentBorder: var(--listitem-selectedFocusColor); + --listitem-selectedFocusCurrentBottomBorder: var(--listitem-selectedFocusBottomBorder); + --listitem-selectedFocusCurrentBackground: var(--listitem-selectedFocusColor); + + color: -moz-FieldText; + margin-inline-start: 1px; + margin-inline-end: 1px; + padding-top: 1px; + padding-bottom: 1px; + border-width: 1px; + background-repeat: no-repeat; + background-size: 100% 100%; + } - listitem[selected="true"] { - border-top-color: var(--listitem-selectedBorder); - border-right-color: var(--listitem-selectedBorder); - border-left-color: var(--listitem-selectedBorder); - border-bottom-color: var(--listitem-selectedBottomBorder); - background-image: var(--listitem-selectedImage); - background-color: var(--listitem-selectedBackground); - color: -moz-DialogText; - } + listitem[selected="true"] { + border-top-color: var(--listitem-selectedBorder); + border-right-color: var(--listitem-selectedBorder); + border-left-color: var(--listitem-selectedBorder); + border-bottom-color: var(--listitem-selectedBottomBorder); + background-image: var(--listitem-selectedImage); + background-color: var(--listitem-selectedBackground); + color: -moz-DialogText; + } - listbox:focus > listitem[selected="true"] { - border-top-color: var(--listitem-selectedFocusBorder); - border-right-color: var(--listitem-selectedFocusBorder); - border-left-color: var(--listitem-selectedFocusBorder); - border-bottom-color: var(--listitem-selectedFocusBottomBorder); - background-image: var(--listitem-selectedFocusImage); - background-color: var(--listitem-selectedFocusBackground); - color: -moz-DialogText; - } + listbox:focus > listitem[selected="true"] { + border-top-color: var(--listitem-selectedFocusBorder); + border-right-color: var(--listitem-selectedFocusBorder); + border-left-color: var(--listitem-selectedFocusBorder); + border-bottom-color: var(--listitem-selectedFocusBottomBorder); + background-image: var(--listitem-selectedFocusImage); + background-color: var(--listitem-selectedFocusBackground); + color: -moz-DialogText; + } - listbox:focus > listitem[current="true"] { - border-color: var(--listitem-selectedCurrentBorder); - outline: none; - } + listbox:focus > listitem[current="true"] { + border-color: var(--listitem-selectedCurrentBorder); + outline: none; + } - listbox:focus > listitem[selected="true"][current="true"] { - border-top-color: var(--listitem-selectedFocusCurrentBorder); - border-right-color: var(--listitem-selectedFocusCurrentBorder); - border-left-color: var(--listitem-selectedFocusCurrentBorder); - border-bottom-color: var(--listitem-selectedFocusCurrentBottomBorder); - background-color: var(--listitem-selectedFocusCurrentBackground); - outline: none; - } + listbox:focus > listitem[selected="true"][current="true"] { + border-top-color: var(--listitem-selectedFocusCurrentBorder); + border-right-color: var(--listitem-selectedFocusCurrentBorder); + border-left-color: var(--listitem-selectedFocusCurrentBorder); + border-bottom-color: var(--listitem-selectedFocusCurrentBottomBorder); + background-color: var(--listitem-selectedFocusCurrentBackground); + outline: none; } - @media (-moz-os-version: windows-vista), - (-moz-os-version: windows-win7) { + @media (-moz-os-version: windows-win7) { listitem { --listitem-selectedBottomBorder: var(--listitem-selectedColor); --listitem-selectedBackground: rgba(190,190,190,.15); diff --git a/toolkit/themes/windows/global/menu.css b/toolkit/themes/windows/global/menu.css index 2a228251d4..c22aedd7a9 100644 --- a/toolkit/themes/windows/global/menu.css +++ b/toolkit/themes/windows/global/menu.css @@ -148,15 +148,13 @@ menubar > menu:-moz-lwtheme[_moz-menuactive="true"]:not([disabled="true"]) { } @media (-moz-windows-default-theme) { - @media not all and (-moz-os-version: windows-xp) { - menubar > menu:-moz-lwtheme { - -moz-appearance: menuitem; - } - - menubar > menu:-moz-lwtheme[_moz-menuactive="true"]:not([disabled="true"]) { - color: inherit !important; - text-shadow: inherit; - } + menubar > menu:-moz-lwtheme { + -moz-appearance: menuitem; + } + + menubar > menu:-moz-lwtheme[_moz-menuactive="true"]:not([disabled="true"]) { + color: inherit !important; + text-shadow: inherit; } } diff --git a/toolkit/themes/windows/global/menulist.css b/toolkit/themes/windows/global/menulist.css index 9480bffdaf..de24dbddec 100644 --- a/toolkit/themes/windows/global/menulist.css +++ b/toolkit/themes/windows/global/menulist.css @@ -82,12 +82,6 @@ menulist:-moz-focusring:not([open="true"]) > .menulist-label-box { border: 1px dotted ThreeDDarkShadow; } -@media (-moz-os-version: windows-xp) { - menulist:-moz-focusring:not([open="true"]) > .menulist-label-box { - border: 1px dotted #F5DB95; - } -} - /* ..... disabled state ..... */ menulist[disabled="true"] { @@ -113,31 +107,29 @@ html|*.menulist-editable-input { } @media (-moz-windows-default-theme) { - @media not all and (-moz-os-version: windows-xp) { - .menulist-label-box { - background-color: transparent !important; - color: inherit !important; - } - - .menulist-label { - margin-top: -1px !important; - margin-bottom: -1px !important; - margin-inline-start: 0 !important; - } - - .menulist-description { - margin-inline-start: 1ex !important; - } - - menulist:not([editable="true"]) > .menulist-dropmarker { - margin-top: -2px; - margin-inline-start: 3px; - margin-inline-end: -3px; - } - - .menulist-icon { - margin-top: -1px; - margin-bottom: -1px; - } + .menulist-label-box { + background-color: transparent !important; + color: inherit !important; + } + + .menulist-label { + margin-top: -1px !important; + margin-bottom: -1px !important; + margin-inline-start: 0 !important; + } + + .menulist-description { + margin-inline-start: 1ex !important; + } + + menulist:not([editable="true"]) > .menulist-dropmarker { + margin-top: -2px; + margin-inline-start: 3px; + margin-inline-end: -3px; + } + + .menulist-icon { + margin-top: -1px; + margin-bottom: -1px; } } diff --git a/toolkit/themes/windows/global/popup.css b/toolkit/themes/windows/global/popup.css index 010e85a932..e5c3c45008 100644 --- a/toolkit/themes/windows/global/popup.css +++ b/toolkit/themes/windows/global/popup.css @@ -58,9 +58,7 @@ panel[type="arrow"][side="right"] { } %ifdef XP_WIN -@media (-moz-os-version: windows-xp), - (-moz-os-version: windows-vista), - (-moz-os-version: windows-win7) { +@media (-moz-os-version: windows-win7) { %endif .panel-arrowcontent { border-radius: 4px; diff --git a/toolkit/themes/windows/global/textbox.css b/toolkit/themes/windows/global/textbox.css index 78ca7f3205..7b136a0ea2 100644 --- a/toolkit/themes/windows/global/textbox.css +++ b/toolkit/themes/windows/global/textbox.css @@ -37,10 +37,8 @@ html|*.textbox-textarea { } @media (-moz-windows-default-theme) { - @media not all and (-moz-os-version: windows-xp) { - textbox html|*.textbox-input::placeholder { - font-style: italic; - } + textbox html|*.textbox-input::placeholder { + font-style: italic; } } diff --git a/toolkit/themes/windows/global/toolbar/spring-XP.png b/toolkit/themes/windows/global/toolbar/spring-XP.png Binary files differdeleted file mode 100644 index e20f602c22..0000000000 --- a/toolkit/themes/windows/global/toolbar/spring-XP.png +++ /dev/null diff --git a/toolkit/themes/windows/global/toolbarbutton.css b/toolkit/themes/windows/global/toolbarbutton.css index e96e529cf3..ac3c7ba4a1 100644 --- a/toolkit/themes/windows/global/toolbarbutton.css +++ b/toolkit/themes/windows/global/toolbarbutton.css @@ -84,17 +84,11 @@ toolbarbutton[checked="true"]:not([disabled="true"]) { text-shadow: none; } - toolbarbutton:-moz-lwtheme:not(:hover):not([checked="true"]):not([open="true"]):not([disabled="true"]) { + toolbarbutton:-moz-lwtheme:not([disabled="true"]) { color: inherit; text-shadow: inherit; } - @media not all and (-moz-os-version: windows-xp) { - toolbarbutton:-moz-lwtheme:not([disabled="true"]) { - color: inherit; - text-shadow: inherit; - } - } } @media not all and (-moz-windows-default-theme) { diff --git a/toolkit/themes/windows/global/tree.css b/toolkit/themes/windows/global/tree.css index 1300968248..2b4957c6c9 100644 --- a/toolkit/themes/windows/global/tree.css +++ b/toolkit/themes/windows/global/tree.css @@ -310,7 +310,7 @@ treecol:not([hideheader="true"]) > .treecol-sortdirection[sortDirection="descend /* ::::: twisty ::::: */ treechildren::-moz-tree-twisty { - padding-inline-end: 4px; + padding-inline-end: 1px; padding-top: 1px; width: 9px; /* The image's width is 9 pixels */ list-style-image: url("chrome://global/skin/tree/twisty.svg#clsd"); @@ -320,8 +320,32 @@ treechildren::-moz-tree-twisty(open) { list-style-image: url("chrome://global/skin/tree/twisty.svg#open"); } +treechildren::-moz-tree-twisty(hover) { + list-style-image: url("chrome://global/skin/tree/twisty.svg#clsd-hover"); +} + +treechildren::-moz-tree-twisty(hover, open) { + list-style-image: url("chrome://global/skin/tree/twisty.svg#open-hover"); +} + +treechildren:-moz-locale-dir(rtl)::-moz-tree-twisty { + list-style-image: url("chrome://global/skin/tree/twisty.svg#clsd-rtl"); +} + +treechildren:-moz-locale-dir(rtl)::-moz-tree-twisty(open) { + list-style-image: url("chrome://global/skin/tree/twisty.svg#open-rtl"); +} + +treechildren:-moz-locale-dir(rtl)::-moz-tree-twisty(hover) { + list-style-image: url("chrome://global/skin/tree/twisty.svg#clsd-hover-rtl"); +} + +treechildren:-moz-locale-dir(rtl)::-moz-tree-twisty(hover, open) { + list-style-image: url("chrome://global/skin/tree/twisty.svg#open-hover-rtl"); +} + treechildren::-moz-tree-indentation { - width: 18px; + width: 12px; } /* ::::: gridline style ::::: */ @@ -370,233 +394,196 @@ treechildren::-moz-tree-cell-text(active, selected, editing) { } %ifdef XP_WIN -@media not all and (-moz-os-version: windows-xp) { - /* ::::: twisty ::::: */ - - treechildren::-moz-tree-indentation { - width: 12px; +@media (-moz-windows-default-theme) { + treechildren { + --treechildren-outline: none; + --treechildren-2ndBorderColor: rgba(255,255,255,.4); + --treechildren-selectedColor: rgb(217,217,217); + --treechildren-focusColor: rgb(123,195,255); + --treechildren-selectedFocusColor: rgb(205,232,255); + --treechildren-currentColor: rgb(125,162,206); + --treechildren-hoverColor: rgb(229,243,255); + --treechildren-selectedBorder: var(--treechildren-selectedColor); + --treechildren-selectedBottomBorder: rgb(204,204,204); + --treechildren-selectedImage: linear-gradient(rgb(217,217,217), rgb(217,217,217)); + --treechildren-selectedBackground: transparent; + --treechildren-currentFocusBorder: var(--treechildren-focusColor); + --treechildren-currentFocusBottomBorder: var(--treechildren-focusColor); + --treechildren-selectedFocusBorder: var(--treechildren-selectedFocusColor); + --treechildren-selectedFocusBottomBorder: rgb(165,214,255); + --treechildren-selectedFocusImage: none; + --treechildren-selectedFocusBackground: var(--treechildren-selectedFocusColor); + --treechildren-selectedFocusCurrentBorder: var(--treechildren-focusColor); + --treechildren-selectedFocusCurrentBottomBorder: var(--treechildren-focusColor); + --treechildren-selectedFocusCurrentImage: linear-gradient(rgb(205,232,255), rgb(205,232,255)); + --treechildren-hoverBorder: var(--treechildren-hoverColor); + --treechildren-hoverBottomBorder: var(--treechildren-hoverColor); + --treechildren-hoverImage: linear-gradient(rgb(229,243,255), rgb(229,243,255)); + --treechildren-hoverCurrentBorder: var(--treechildren-currentColor); + --treechildren-hoverCurrentBottomBorder: var(--treechildren-currentColor); + --treechildren-hoverCurrentImage: linear-gradient(rgba(131,183,249,.16), rgba(131,183,249,.16)); + --treechildren-hoverSelectedBorder: var(--treechildren-focusColor); + --treechildren-hoverSelectedBottomBorder: var(--treechildren-focusColor); + --treechildren-hoverSelectedImage: linear-gradient(rgb(205,232,255), rgb(205,232,255)); } - treechildren::-moz-tree-twisty { - padding-inline-end: 1px; + treechildren:not(.autocomplete-treebody)::-moz-tree-row { + height: 1.8em; + color: -moz-FieldText; + margin-inline-start: 1px; + margin-inline-end: 1px; + border-width: 1px; + border-color: transparent; + background-repeat: no-repeat; + background-size: 100% 100%; } - treechildren::-moz-tree-twisty(hover) { - list-style-image: url("chrome://global/skin/tree/twisty.svg#clsd-hover"); + treechildren:not(.autocomplete-treebody)::-moz-tree-row(selected) { + -moz-border-top-colors: var(--treechildren-selectedBorder); + -moz-border-right-colors: var(--treechildren-selectedBorder); + -moz-border-left-colors: var(--treechildren-selectedBorder); + -moz-border-bottom-colors: var(--treechildren-selectedBottomBorder); + background-image: var(--treechildren-selectedImage); + background-color: var(--treechildren-selectedBackground); + outline: var(--treechildren-outline); } - treechildren::-moz-tree-twisty(hover, open) { - list-style-image: url("chrome://global/skin/tree/twisty.svg#open-hover"); + treechildren:not(.autocomplete-treebody)::-moz-tree-row(current, focus) { + border-style: solid; + -moz-border-top-colors: var(--treechildren-currentFocusBorder); + -moz-border-right-colors: var(--treechildren-currentFocusBorder); + -moz-border-left-colors: var(--treechildren-currentFocusBorder); + -moz-border-bottom-colors: var(--treechildren-currentFocusBottomBorder); + outline: var(--treechildren-outline); } - treechildren:-moz-locale-dir(rtl)::-moz-tree-twisty { - list-style-image: url("chrome://global/skin/tree/twisty.svg#clsd-rtl"); + treechildren:not(.autocomplete-treebody)::-moz-tree-row(selected, focus), + treechildren::-moz-tree-row(dropOn) { + -moz-border-top-colors: var(--treechildren-selectedFocusBorder); + -moz-border-right-colors: var(--treechildren-selectedFocusBorder); + -moz-border-left-colors: var(--treechildren-selectedFocusBorder); + -moz-border-bottom-colors: var(--treechildren-selectedFocusBottomBorder); + background-image: var(--treechildren-selectedFocusImage); + background-color: var(--treechildren-selectedFocusBackground); } - treechildren:-moz-locale-dir(rtl)::-moz-tree-twisty(open) { - list-style-image: url("chrome://global/skin/tree/twisty.svg#open-rtl"); + treechildren:not(.autocomplete-treebody)::-moz-tree-row(selected, current, focus) { + border-style: solid; + -moz-border-top-colors: var(--treechildren-selectedFocusCurrentBorder); + -moz-border-right-colors: var(--treechildren-selectedFocusCurrentBorder); + -moz-border-left-colors: var(--treechildren-selectedFocusCurrentBorder); + -moz-border-bottom-colors: var(--treechildren-selectedFocusCurrentBottomBorder); + background-image: var(--treechildren-selectedFocusCurrentImage); } - treechildren:-moz-locale-dir(rtl)::-moz-tree-twisty(hover) { - list-style-image: url("chrome://global/skin/tree/twisty.svg#clsd-hover-rtl"); + treechildren:not(.autocomplete-treebody)::-moz-tree-row(hover) { + -moz-border-top-colors: var(--treechildren-hoverBorder); + -moz-border-right-colors: var(--treechildren-hoverBorder); + -moz-border-left-colors: var(--treechildren-hoverBorder); + -moz-border-bottom-colors: var(--treechildren-hoverBottomBorder); + background-image: var(--treechildren-hoverImage); + outline: var(--treechildren-outline); } - treechildren:-moz-locale-dir(rtl)::-moz-tree-twisty(hover, open) { - list-style-image: url("chrome://global/skin/tree/twisty.svg#open-hover-rtl"); + treechildren:not(.autocomplete-treebody)::-moz-tree-row(hover, current) { + -moz-border-top-colors: var(--treechildren-hoverCurrentBorder); + -moz-border-right-colors: var(--treechildren-hoverCurrentBorder); + -moz-border-left-colors: var(--treechildren-hoverCurrentBorder); + -moz-border-bottom-colors: var(--treechildren-hoverCurrentBottomBorder); + background-image: var(--treechildren-hoverCurrentImage); } - @media (-moz-windows-default-theme) { - treechildren { - --treechildren-outline: none; - --treechildren-2ndBorderColor: rgba(255,255,255,.4); - --treechildren-selectedColor: rgb(217,217,217); - --treechildren-focusColor: rgb(123,195,255); - --treechildren-selectedFocusColor: rgb(205,232,255); - --treechildren-currentColor: rgb(125,162,206); - --treechildren-hoverColor: rgb(229,243,255); - --treechildren-selectedBorder: var(--treechildren-selectedColor); - --treechildren-selectedBottomBorder: rgb(204,204,204); - --treechildren-selectedImage: linear-gradient(rgb(217,217,217), rgb(217,217,217)); - --treechildren-selectedBackground: transparent; - --treechildren-currentFocusBorder: var(--treechildren-focusColor); - --treechildren-currentFocusBottomBorder: var(--treechildren-focusColor); - --treechildren-selectedFocusBorder: var(--treechildren-selectedFocusColor); - --treechildren-selectedFocusBottomBorder: rgb(165,214,255); - --treechildren-selectedFocusImage: none; - --treechildren-selectedFocusBackground: var(--treechildren-selectedFocusColor); - --treechildren-selectedFocusCurrentBorder: var(--treechildren-focusColor); - --treechildren-selectedFocusCurrentBottomBorder: var(--treechildren-focusColor); - --treechildren-selectedFocusCurrentImage: linear-gradient(rgb(205,232,255), rgb(205,232,255)); - --treechildren-hoverBorder: var(--treechildren-hoverColor); - --treechildren-hoverBottomBorder: var(--treechildren-hoverColor); - --treechildren-hoverImage: linear-gradient(rgb(229,243,255), rgb(229,243,255)); - --treechildren-hoverCurrentBorder: var(--treechildren-currentColor); - --treechildren-hoverCurrentBottomBorder: var(--treechildren-currentColor); - --treechildren-hoverCurrentImage: linear-gradient(rgba(131,183,249,.16), rgba(131,183,249,.16)); - --treechildren-hoverSelectedBorder: var(--treechildren-focusColor); - --treechildren-hoverSelectedBottomBorder: var(--treechildren-focusColor); - --treechildren-hoverSelectedImage: linear-gradient(rgb(205,232,255), rgb(205,232,255)); - } - - treechildren:not(.autocomplete-treebody)::-moz-tree-row { - height: 1.8em; - color: -moz-FieldText; - margin-inline-start: 1px; - margin-inline-end: 1px; - border-width: 1px; - border-color: transparent; - background-repeat: no-repeat; - background-size: 100% 100%; - } - - treechildren:not(.autocomplete-treebody)::-moz-tree-row(selected) { - -moz-border-top-colors: var(--treechildren-selectedBorder); - -moz-border-right-colors: var(--treechildren-selectedBorder); - -moz-border-left-colors: var(--treechildren-selectedBorder); - -moz-border-bottom-colors: var(--treechildren-selectedBottomBorder); - background-image: var(--treechildren-selectedImage); - background-color: var(--treechildren-selectedBackground); - outline: var(--treechildren-outline); - } - - treechildren:not(.autocomplete-treebody)::-moz-tree-row(current, focus) { - border-style: solid; - -moz-border-top-colors: var(--treechildren-currentFocusBorder); - -moz-border-right-colors: var(--treechildren-currentFocusBorder); - -moz-border-left-colors: var(--treechildren-currentFocusBorder); - -moz-border-bottom-colors: var(--treechildren-currentFocusBottomBorder); - outline: var(--treechildren-outline); - } - - treechildren:not(.autocomplete-treebody)::-moz-tree-row(selected, focus), - treechildren::-moz-tree-row(dropOn) { - -moz-border-top-colors: var(--treechildren-selectedFocusBorder); - -moz-border-right-colors: var(--treechildren-selectedFocusBorder); - -moz-border-left-colors: var(--treechildren-selectedFocusBorder); - -moz-border-bottom-colors: var(--treechildren-selectedFocusBottomBorder); - background-image: var(--treechildren-selectedFocusImage); - background-color: var(--treechildren-selectedFocusBackground); - } - - treechildren:not(.autocomplete-treebody)::-moz-tree-row(selected, current, focus) { - border-style: solid; - -moz-border-top-colors: var(--treechildren-selectedFocusCurrentBorder); - -moz-border-right-colors: var(--treechildren-selectedFocusCurrentBorder); - -moz-border-left-colors: var(--treechildren-selectedFocusCurrentBorder); - -moz-border-bottom-colors: var(--treechildren-selectedFocusCurrentBottomBorder); - background-image: var(--treechildren-selectedFocusCurrentImage); - } - - treechildren:not(.autocomplete-treebody)::-moz-tree-row(hover) { - -moz-border-top-colors: var(--treechildren-hoverBorder); - -moz-border-right-colors: var(--treechildren-hoverBorder); - -moz-border-left-colors: var(--treechildren-hoverBorder); - -moz-border-bottom-colors: var(--treechildren-hoverBottomBorder); - background-image: var(--treechildren-hoverImage); - outline: var(--treechildren-outline); - } - - treechildren:not(.autocomplete-treebody)::-moz-tree-row(hover, current) { - -moz-border-top-colors: var(--treechildren-hoverCurrentBorder); - -moz-border-right-colors: var(--treechildren-hoverCurrentBorder); - -moz-border-left-colors: var(--treechildren-hoverCurrentBorder); - -moz-border-bottom-colors: var(--treechildren-hoverCurrentBottomBorder); - background-image: var(--treechildren-hoverCurrentImage); - } + treechildren:not(.autocomplete-treebody)::-moz-tree-row(hover, selected) { + -moz-border-top-colors: var(--treechildren-hoverSelectedBorder); + -moz-border-right-colors: var(--treechildren-hoverSelectedBorder); + -moz-border-left-colors: var(--treechildren-hoverSelectedBorder); + -moz-border-bottom-colors: var(--treechildren-hoverSelectedBottomBorder); + background-image: var(--treechildren-hoverSelectedImage); + } - treechildren:not(.autocomplete-treebody)::-moz-tree-row(hover, selected) { - -moz-border-top-colors: var(--treechildren-hoverSelectedBorder); - -moz-border-right-colors: var(--treechildren-hoverSelectedBorder); - -moz-border-left-colors: var(--treechildren-hoverSelectedBorder); - -moz-border-bottom-colors: var(--treechildren-hoverSelectedBottomBorder); - background-image: var(--treechildren-hoverSelectedImage); - } + tree[disabled="true"] > treechildren::-moz-tree-row { + background: none; + -moz-border-top-colors: transparent; + -moz-border-right-colors: transparent; + -moz-border-left-colors: transparent; + -moz-border-bottom-colors: transparent; + } - tree[disabled="true"] > treechildren::-moz-tree-row { - background: none; - -moz-border-top-colors: transparent; - -moz-border-right-colors: transparent; - -moz-border-left-colors: transparent; - -moz-border-bottom-colors: transparent; - } + treechildren::-moz-tree-cell(dropOn) { + background-image: none; + background-color: transparent; + border-radius: 0; + } - treechildren::-moz-tree-cell(dropOn) { - background-image: none; - background-color: transparent; - border-radius: 0; - } + treechildren::-moz-tree-cell-text(primary, dropOn) { + color: -moz-FieldText; + } - treechildren::-moz-tree-cell-text(primary, dropOn) { - color: -moz-FieldText; - } + treechildren:not(.autocomplete-treebody)::-moz-tree-cell-text { + padding-bottom: initial; + border-color: transparent; + background-color: transparent; + } - treechildren:not(.autocomplete-treebody)::-moz-tree-cell-text { - padding-bottom: initial; - border-color: transparent; - background-color: transparent; - } + treechildren:not(.autocomplete-treebody)::-moz-tree-cell-text(selected, focus) { + color: -moz-DialogText; + } - treechildren:not(.autocomplete-treebody)::-moz-tree-cell-text(selected, focus) { - color: -moz-DialogText; + @media (-moz-os-version: windows-win7) { + treechildren { + --treechildren-outline: 1px solid var(--treechildren-2ndBorderColor); + --treechildren-2ndBottomBorderColor: rgba(255,255,255,.6); + --treechildren-selectedBorder: var(--treechildren-selectedColor) var(--treechildren-2ndBorderColor); + --treechildren-selectedBottomBorder: var(--treechildren-selectedColor) var(--treechildren-2ndBottomBorderColor); + --treechildren-selectedImage: linear-gradient(rgba(190,190,190,.1), rgba(190,190,190,.4)); + --treechildren-currentFocusBorder: var(--treechildren-currentColor) var(--treechildren-2ndBorderColor); + --treechildren-currentFocusBottomBorder: var(--treechildren-currentColor) var(--treechildren-2ndBottomBorderColor); + --treechildren-selectedFocusBorder: rgb(132,172,221) var(--treechildren-2ndBorderColor); + --treechildren-selectedFocusBottomBorder: var(--treechildren-currentColor) var(--treechildren-2ndBottomBorderColor); + --treechildren-selectedFocusImage: linear-gradient(rgba(131,183,249,.16), rgba(131,183,249,.375)); + --treechildren-selectedFocusBackground: transparent; + --treechildren-selectedFocusCurrentBorder: var(--treechildren-currentColor) var(--treechildren-2ndBorderColor); + --treechildren-selectedFocusCurrentBottomBorder: var(--treechildren-currentColor) var(--treechildren-2ndBottomBorderColor); + --treechildren-selectedFocusCurrentImage: linear-gradient(rgba(131,183,249,.28), rgba(131,183,249,.5)); + --treechildren-hoverBorder: rgb(184,214,251) var(--treechildren-2ndBorderColor); + --treechildren-hoverBottomBorder: rgb(184,214,251) var(--treechildren-2ndBottomBorderColor); + --treechildren-hoverImage: linear-gradient(rgba(131,183,249,.05), rgba(131,183,249,.16)); + --treechildren-hoverCurrentBorder: var(--treechildren-currentColor) var(--treechildren-2ndBorderColor); + --treechildren-hoverCurrentBottomBorder: var(--treechildren-currentColor) var(--treechildren-2ndBottomBorderColor); + --treechildren-hoverCurrentImage: linear-gradient(rgba(131,183,249,.05), rgba(131,183,249,.16)); + --treechildren-hoverSelectedBorder: var(--treechildren-currentColor) var(--treechildren-2ndBorderColor); + --treechildren-hoverSelectedBottomBorder: var(--treechildren-currentColor) var(--treechildren-2ndBottomBorderColor); + --treechildren-hoverSelectedImage: linear-gradient(rgba(131,183,249,.28), rgba(131,183,249,.5)); } - @media (-moz-os-version: windows-vista), - (-moz-os-version: windows-win7) { - treechildren { - --treechildren-outline: 1px solid var(--treechildren-2ndBorderColor); - --treechildren-2ndBottomBorderColor: rgba(255,255,255,.6); - --treechildren-selectedBorder: var(--treechildren-selectedColor) var(--treechildren-2ndBorderColor); - --treechildren-selectedBottomBorder: var(--treechildren-selectedColor) var(--treechildren-2ndBottomBorderColor); - --treechildren-selectedImage: linear-gradient(rgba(190,190,190,.1), rgba(190,190,190,.4)); - --treechildren-currentFocusBorder: var(--treechildren-currentColor) var(--treechildren-2ndBorderColor); - --treechildren-currentFocusBottomBorder: var(--treechildren-currentColor) var(--treechildren-2ndBottomBorderColor); - --treechildren-selectedFocusBorder: rgb(132,172,221) var(--treechildren-2ndBorderColor); - --treechildren-selectedFocusBottomBorder: var(--treechildren-currentColor) var(--treechildren-2ndBottomBorderColor); - --treechildren-selectedFocusImage: linear-gradient(rgba(131,183,249,.16), rgba(131,183,249,.375)); - --treechildren-selectedFocusBackground: transparent; - --treechildren-selectedFocusCurrentBorder: var(--treechildren-currentColor) var(--treechildren-2ndBorderColor); - --treechildren-selectedFocusCurrentBottomBorder: var(--treechildren-currentColor) var(--treechildren-2ndBottomBorderColor); - --treechildren-selectedFocusCurrentImage: linear-gradient(rgba(131,183,249,.28), rgba(131,183,249,.5)); - --treechildren-hoverBorder: rgb(184,214,251) var(--treechildren-2ndBorderColor); - --treechildren-hoverBottomBorder: rgb(184,214,251) var(--treechildren-2ndBottomBorderColor); - --treechildren-hoverImage: linear-gradient(rgba(131,183,249,.05), rgba(131,183,249,.16)); - --treechildren-hoverCurrentBorder: var(--treechildren-currentColor) var(--treechildren-2ndBorderColor); - --treechildren-hoverCurrentBottomBorder: var(--treechildren-currentColor) var(--treechildren-2ndBottomBorderColor); - --treechildren-hoverCurrentImage: linear-gradient(rgba(131,183,249,.05), rgba(131,183,249,.16)); - --treechildren-hoverSelectedBorder: var(--treechildren-currentColor) var(--treechildren-2ndBorderColor); - --treechildren-hoverSelectedBottomBorder: var(--treechildren-currentColor) var(--treechildren-2ndBottomBorderColor); - --treechildren-hoverSelectedImage: linear-gradient(rgba(131,183,249,.28), rgba(131,183,249,.5)); - } - - treechildren:not(.autocomplete-treebody)::-moz-tree-row { - border-width: 2px; - border-radius: 3px; - -moz-outline-radius: 3px; - } + treechildren:not(.autocomplete-treebody)::-moz-tree-row { + border-width: 2px; + border-radius: 3px; + -moz-outline-radius: 3px; } + } - @media (-moz-os-version: windows-win8) { - treechildren { - --treechildren-outline: 1px solid var(--treechildren-2ndBorderColor); - --treechildren-selectedBorder: var(--treechildren-selectedColor); - --treechildren-selectedBottomBorder: var(--treechildren-selectedColor); - --treechildren-selectedImage: linear-gradient(rgba(190,190,190,.4), rgba(190,190,190,.4)); - --treechildren-currentFocusBorder: var(--treechildren-currentColor); - --treechildren-currentFocusBottomBorder: var(--treechildren-currentColor); - --treechildren-selectedFocusBorder: rgb(132,172,221) var(--treechildren-2ndBorderColor); - --treechildren-selectedFocusBottomBorder: var(--treechildren-currentColor); - --treechildren-selectedFocusImage: linear-gradient(rgba(131,183,249,.375), rgba(131,183,249,.375)); - --treechildren-selectedFocusBackground: transparent; - --treechildren-selectedFocusCurrentBorder: var(--treechildren-currentColor); - --treechildren-selectedFocusCurrentBottomBorder: var(--treechildren-currentColor); - --treechildren-selectedFocusCurrentImage: linear-gradient(rgba(131,183,249,.5), rgba(131,183,249,.5)); - --treechildren-hoverBorder: rgb(184,214,251); - --treechildren-hoverBottomBorder: rgb(184,214,251); - --treechildren-hoverImage: linear-gradient(rgba(131,183,249,.16), rgba(131,183,249,.16)); - --treechildren-hoverSelectedBorder: var(--treechildren-currentColor); - --treechildren-hoverSelectedBottomBorder: var(--treechildren-currentColor); - --treechildren-hoverSelectedImage: linear-gradient(rgba(131,183,249,.5), rgba(131,183,249,.5)); - } + @media (-moz-os-version: windows-win8) { + treechildren { + --treechildren-outline: 1px solid var(--treechildren-2ndBorderColor); + --treechildren-selectedBorder: var(--treechildren-selectedColor); + --treechildren-selectedBottomBorder: var(--treechildren-selectedColor); + --treechildren-selectedImage: linear-gradient(rgba(190,190,190,.4), rgba(190,190,190,.4)); + --treechildren-currentFocusBorder: var(--treechildren-currentColor); + --treechildren-currentFocusBottomBorder: var(--treechildren-currentColor); + --treechildren-selectedFocusBorder: rgb(132,172,221) var(--treechildren-2ndBorderColor); + --treechildren-selectedFocusBottomBorder: var(--treechildren-currentColor); + --treechildren-selectedFocusImage: linear-gradient(rgba(131,183,249,.375), rgba(131,183,249,.375)); + --treechildren-selectedFocusBackground: transparent; + --treechildren-selectedFocusCurrentBorder: var(--treechildren-currentColor); + --treechildren-selectedFocusCurrentBottomBorder: var(--treechildren-currentColor); + --treechildren-selectedFocusCurrentImage: linear-gradient(rgba(131,183,249,.5), rgba(131,183,249,.5)); + --treechildren-hoverBorder: rgb(184,214,251); + --treechildren-hoverBottomBorder: rgb(184,214,251); + --treechildren-hoverImage: linear-gradient(rgba(131,183,249,.16), rgba(131,183,249,.16)); + --treechildren-hoverSelectedBorder: var(--treechildren-currentColor); + --treechildren-hoverSelectedBottomBorder: var(--treechildren-currentColor); + --treechildren-hoverSelectedImage: linear-gradient(rgba(131,183,249,.5), rgba(131,183,249,.5)); } } } diff --git a/toolkit/themes/windows/global/tree/sort-asc-XP.png b/toolkit/themes/windows/global/tree/sort-asc-XP.png Binary files differdeleted file mode 100644 index 64d077a8f4..0000000000 --- a/toolkit/themes/windows/global/tree/sort-asc-XP.png +++ /dev/null diff --git a/toolkit/themes/windows/global/tree/sort-dsc-XP.png b/toolkit/themes/windows/global/tree/sort-dsc-XP.png Binary files differdeleted file mode 100644 index 9c4a82587c..0000000000 --- a/toolkit/themes/windows/global/tree/sort-dsc-XP.png +++ /dev/null diff --git a/toolkit/themes/windows/global/tree/twisty-XP.svg b/toolkit/themes/windows/global/tree/twisty-XP.svg deleted file mode 100644 index 66219d513e..0000000000 --- a/toolkit/themes/windows/global/tree/twisty-XP.svg +++ /dev/null @@ -1,33 +0,0 @@ -<?xml version="1.0"?> -<!-- This Source Code Form is subject to the terms of the Mozilla Public - - License, v. 2.0. If a copy of the MPL was not distributed with this - - file, You can obtain one at http://mozilla.org/MPL/2.0/. --> -<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="9" height="9"> - <style> - use:not(:target) { - display: none; - } - use { - stroke: #000000; - stroke-width: 1; - } - </style> - <defs> - <linearGradient id="linearGradient1"> - <stop style="stop-color: #ffffff;" offset="0"/> - <stop style="stop-color: #e0e0e0;" offset="1"/> - </linearGradient> - <linearGradient id="linearGradient2"> - <stop style="stop-color: #c9c9c9;" offset="0"/> - <stop style="stop-color: #f8f8f8;" offset="1"/> - </linearGradient> - <linearGradient id="gradient1" xlink:href="#linearGradient1" gradientUnits="userSpaceOnUse" x1="4.5" y1="2" x2="4.5" y2="7"/> - <linearGradient id="gradient2" xlink:href="#linearGradient2" gradientUnits="userSpaceOnUse" x1="4.5" y1="6" x2="4.5" y2="3"/> - <path id="clsd-shape" d="m 2,4.5 5,0 M 4.5,2 l 0,5"/> - <path id="open-shape" d="m 2,4.5 5,0"/> - </defs> - <rect style="fill: url(#gradient1); stroke: #5d5cc2; stroke-linejoin: round; stroke-opacity: 0.8" width="8" height="8" x="0.5" y="0.5"/> - <rect style="fill: url(#gradient2);" width="5" height="5" x="2" y="2"/> - <use id="clsd" xlink:href="#clsd-shape"/> - <use id="open" xlink:href="#open-shape"/> -</svg> diff --git a/toolkit/themes/windows/global/tree/twisty-Vista78.svg b/toolkit/themes/windows/global/tree/twisty-preWin10.svg index 0a69086346..0a69086346 100644 --- a/toolkit/themes/windows/global/tree/twisty-Vista78.svg +++ b/toolkit/themes/windows/global/tree/twisty-preWin10.svg diff --git a/toolkit/themes/windows/mozapps/downloads/downloadButtons-XP.png b/toolkit/themes/windows/mozapps/downloads/downloadButtons-XP.png Binary files differdeleted file mode 100644 index d36385ce53..0000000000 --- a/toolkit/themes/windows/mozapps/downloads/downloadButtons-XP.png +++ /dev/null diff --git a/toolkit/themes/windows/mozapps/downloads/downloadIcon-XP.png b/toolkit/themes/windows/mozapps/downloads/downloadIcon-XP.png Binary files differdeleted file mode 100644 index 8225b6c2dc..0000000000 --- a/toolkit/themes/windows/mozapps/downloads/downloadIcon-XP.png +++ /dev/null diff --git a/toolkit/themes/windows/mozapps/jar.mn b/toolkit/themes/windows/mozapps/jar.mn index 5986f18f12..29203811f3 100644 --- a/toolkit/themes/windows/mozapps/jar.mn +++ b/toolkit/themes/windows/mozapps/jar.mn @@ -22,16 +22,8 @@ toolkit.jar: skin/classic/mozapps/extensions/localeGeneric.png (webextensions/localeGeneric.png) skin/classic/mozapps/extensions/heart.png (webextensions/heart.png) * skin/classic/mozapps/extensions/newaddon.css (webextensions/newaddon.css) - skin/classic/mozapps/extensions/category-discover-XP.png (webextensions/category-discover-XP.png) - skin/classic/mozapps/extensions/category-plugins-XP.png (webextensions/category-plugins-XP.png) - skin/classic/mozapps/extensions/category-recent-XP.png (webextensions/category-recent-XP.png) - skin/classic/mozapps/extensions/category-available-XP.png (webextensions/category-available-XP.png) - skin/classic/mozapps/extensions/extensionGeneric-16-XP.png (webextensions/extensionGeneric-16-XP.png) - skin/classic/mozapps/extensions/themeGeneric-XP.png (webextensions/themeGeneric-XP.png) - skin/classic/mozapps/extensions/themeGeneric-16-XP.png (webextensions/themeGeneric-16-XP.png) - skin/classic/mozapps/extensions/localeGeneric-XP.png (webextensions/localeGeneric-XP.png) #else - skin/classic/mozapps/extensions/about.css (extensions/about.css) + skin/classic/mozapps/extensions/about.css (extensions/about.css) skin/classic/mozapps/extensions/blocklist.css (extensions/blocklist.css) * skin/classic/mozapps/extensions/extensions.css (extensions/extensions.css) * skin/classic/mozapps/extensions/selectAddons.css (extensions/selectAddons.css) @@ -82,33 +74,9 @@ toolkit.jar: skin/classic/mozapps/profile/profileicon.png (profile/profileicon.png) skin/classic/mozapps/update/updates.css (update/updates.css) skin/classic/mozapps/viewsource/viewsource.css (viewsource/viewsource.css) - skin/classic/mozapps/downloads/downloadButtons-XP.png (downloads/downloadButtons-XP.png) - skin/classic/mozapps/downloads/downloadIcon-XP.png (downloads/downloadIcon-XP.png) - skin/classic/mozapps/plugins/pluginGeneric-XP.png (plugins/pluginGeneric-XP.png) - skin/classic/mozapps/plugins/pluginBlocked-XP.png (plugins/pluginBlocked-XP.png) - skin/classic/mozapps/plugins/pluginGeneric-16-XP.png (plugins/pluginGeneric-16-XP.png) - skin/classic/mozapps/profile/profileicon-XP.png (profile/profileicon-XP.png) - skin/classic/mozapps/update/downloadButtons-XP.png (update/downloadButtons-XP.png) #ifdef MOZ_PHOENIX [browser/extensions/{972ce4c6-7e08-4474-a285-3208198ce6fd}] chrome.jar: #elif MOZ_SEPARATE_MANIFEST_FOR_THEME_OVERRIDES [extensions/{972ce4c6-7e08-4474-a285-3208198ce6fd}] chrome.jar: #endif -% override chrome://mozapps/skin/downloads/downloadButtons.png chrome://mozapps/skin/downloads/downloadButtons-XP.png osversion<6 -% override chrome://mozapps/skin/downloads/downloadIcon.png chrome://mozapps/skin/downloads/downloadIcon-XP.png osversion<6 -#ifdef MOZ_WEBEXTENSIONS -% override chrome://mozapps/skin/extensions/category-discover.png chrome://mozapps/skin/extensions/category-discover-XP.png osversion<6 -% override chrome://mozapps/skin/extensions/category-plugins.png chrome://mozapps/skin/extensions/category-plugins-XP.png osversion<6 -% override chrome://mozapps/skin/extensions/category-recent.png chrome://mozapps/skin/extensions/category-recent-XP.png osversion<6 -% override chrome://mozapps/skin/extensions/category-available.png chrome://mozapps/skin/extensions/category-available-XP.png osversion<6 -% override chrome://mozapps/skin/extensions/extensionGeneric-16.png chrome://mozapps/skin/extensions/extensionGeneric-16-XP.png osversion<6 -% override chrome://mozapps/skin/extensions/themeGeneric.png chrome://mozapps/skin/extensions/themeGeneric-XP.png osversion<6 -% override chrome://mozapps/skin/extensions/themeGeneric-16.png chrome://mozapps/skin/extensions/themeGeneric-16-XP.png osversion<6 -% override chrome://mozapps/skin/extensions/localeGeneric.png chrome://mozapps/skin/extensions/localeGeneric-XP.png osversion<6 -#endif -% override chrome://mozapps/skin/plugins/pluginGeneric.png chrome://mozapps/skin/plugins/pluginGeneric-XP.png osversion<6 -% override chrome://mozapps/skin/plugins/pluginBlocked.png chrome://mozapps/skin/plugins/pluginBlocked-XP.png osversion<6 -% override chrome://mozapps/skin/plugins/pluginGeneric-16.png chrome://mozapps/skin/plugins/pluginGeneric-16-XP.png osversion<6 -% override chrome://mozapps/skin/profile/profileicon.png chrome://mozapps/skin/profile/profileicon-XP.png osversion<6 -% override chrome://mozapps/skin/update/downloadButtons.png chrome://mozapps/skin/update/downloadButtons-XP.png osversion<6 diff --git a/toolkit/themes/windows/mozapps/plugins/pluginBlocked-XP.png b/toolkit/themes/windows/mozapps/plugins/pluginBlocked-XP.png Binary files differdeleted file mode 100644 index 954036c1f0..0000000000 --- a/toolkit/themes/windows/mozapps/plugins/pluginBlocked-XP.png +++ /dev/null diff --git a/toolkit/themes/windows/mozapps/plugins/pluginGeneric-16-XP.png b/toolkit/themes/windows/mozapps/plugins/pluginGeneric-16-XP.png Binary files differdeleted file mode 100644 index d6dffb29b4..0000000000 --- a/toolkit/themes/windows/mozapps/plugins/pluginGeneric-16-XP.png +++ /dev/null diff --git a/toolkit/themes/windows/mozapps/plugins/pluginGeneric-XP.png b/toolkit/themes/windows/mozapps/plugins/pluginGeneric-XP.png Binary files differdeleted file mode 100644 index 3e6d43c9ac..0000000000 --- a/toolkit/themes/windows/mozapps/plugins/pluginGeneric-XP.png +++ /dev/null diff --git a/toolkit/themes/windows/mozapps/profile/profileicon-XP.png b/toolkit/themes/windows/mozapps/profile/profileicon-XP.png Binary files differdeleted file mode 100644 index 0854ee1774..0000000000 --- a/toolkit/themes/windows/mozapps/profile/profileicon-XP.png +++ /dev/null diff --git a/toolkit/themes/windows/mozapps/update/downloadButtons-XP.png b/toolkit/themes/windows/mozapps/update/downloadButtons-XP.png Binary files differdeleted file mode 100644 index d36385ce53..0000000000 --- a/toolkit/themes/windows/mozapps/update/downloadButtons-XP.png +++ /dev/null diff --git a/toolkit/themes/windows/mozapps/webextensions/category-available-XP.png b/toolkit/themes/windows/mozapps/webextensions/category-available-XP.png Binary files differdeleted file mode 100644 index d1b737ab05..0000000000 --- a/toolkit/themes/windows/mozapps/webextensions/category-available-XP.png +++ /dev/null diff --git a/toolkit/themes/windows/mozapps/webextensions/category-discover-XP.png b/toolkit/themes/windows/mozapps/webextensions/category-discover-XP.png Binary files differdeleted file mode 100644 index a6f5b49b37..0000000000 --- a/toolkit/themes/windows/mozapps/webextensions/category-discover-XP.png +++ /dev/null diff --git a/toolkit/themes/windows/mozapps/webextensions/category-plugins-XP.png b/toolkit/themes/windows/mozapps/webextensions/category-plugins-XP.png Binary files differdeleted file mode 100644 index 5c4d8bf471..0000000000 --- a/toolkit/themes/windows/mozapps/webextensions/category-plugins-XP.png +++ /dev/null diff --git a/toolkit/themes/windows/mozapps/webextensions/category-recent-XP.png b/toolkit/themes/windows/mozapps/webextensions/category-recent-XP.png Binary files differdeleted file mode 100644 index 7ecfc7d4c8..0000000000 --- a/toolkit/themes/windows/mozapps/webextensions/category-recent-XP.png +++ /dev/null diff --git a/toolkit/themes/windows/mozapps/webextensions/extensionGeneric-16-XP.png b/toolkit/themes/windows/mozapps/webextensions/extensionGeneric-16-XP.png Binary files differdeleted file mode 100644 index 36e7689a30..0000000000 --- a/toolkit/themes/windows/mozapps/webextensions/extensionGeneric-16-XP.png +++ /dev/null diff --git a/toolkit/themes/windows/mozapps/webextensions/localeGeneric-XP.png b/toolkit/themes/windows/mozapps/webextensions/localeGeneric-XP.png Binary files differdeleted file mode 100644 index 4d9ac5ad89..0000000000 --- a/toolkit/themes/windows/mozapps/webextensions/localeGeneric-XP.png +++ /dev/null diff --git a/toolkit/themes/windows/mozapps/webextensions/themeGeneric-16-XP.png b/toolkit/themes/windows/mozapps/webextensions/themeGeneric-16-XP.png Binary files differdeleted file mode 100644 index 16d77a4a25..0000000000 --- a/toolkit/themes/windows/mozapps/webextensions/themeGeneric-16-XP.png +++ /dev/null diff --git a/toolkit/themes/windows/mozapps/webextensions/themeGeneric-XP.png b/toolkit/themes/windows/mozapps/webextensions/themeGeneric-XP.png Binary files differdeleted file mode 100644 index be645f76df..0000000000 --- a/toolkit/themes/windows/mozapps/webextensions/themeGeneric-XP.png +++ /dev/null diff --git a/widget/LookAndFeel.h b/widget/LookAndFeel.h index 443852330d..cf84b33086 100644 --- a/widget/LookAndFeel.h +++ b/widget/LookAndFeel.h @@ -440,10 +440,7 @@ public: * Operating system versions. */ enum OperatingSystemVersion { - // XXX: The XP and Vista values can now be removed (see bug 1330146). - eOperatingSystemVersion_WindowsXP = 0, - eOperatingSystemVersion_WindowsVista, - eOperatingSystemVersion_Windows7, + eOperatingSystemVersion_Windows7 = 2, eOperatingSystemVersion_Windows8, eOperatingSystemVersion_Windows10, eOperatingSystemVersion_Unknown |