From a8ae9cf9176ae90285c27e38a71670a6757837c1 Mon Sep 17 00:00:00 2001 From: Tim Taubert Date: Sun, 6 Apr 2014 06:01:49 +0200 Subject: [PATCH 1/4] Bug 842511 - Specify a character set for directory listings r=gavin --- content/base/test/test_bug431701.html | 1 + testing/mochitest/server.js | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/content/base/test/test_bug431701.html b/content/base/test/test_bug431701.html index 9f6201b557df..9261afa37531 100644 --- a/content/base/test/test_bug431701.html +++ b/content/base/test/test_bug431701.html @@ -4,6 +4,7 @@ https://bugzilla.mozilla.org/show_bug.cgi?id=431701 --> + Test for Bug 431701 diff --git a/testing/mochitest/server.js b/testing/mochitest/server.js index 4292a5ce8c8e..de3ec37b91a0 100644 --- a/testing/mochitest/server.js +++ b/testing/mochitest/server.js @@ -678,7 +678,7 @@ function testListing(metadata, response) function defaultDirHandler(metadata, response) { response.setStatusLine("1.1", 200, "OK"); - response.setHeader("Content-type", "text/html", false); + response.setHeader("Content-type", "text/html;charset=utf-8", false); try { if (metadata.path.indexOf("/tests") != 0) { regularListing(metadata, response); From bdeb22f6e78fde1d5124599f7462b84307d4a096 Mon Sep 17 00:00:00 2001 From: Philipp Sackl Date: Sat, 5 Apr 2014 13:40:50 -0700 Subject: [PATCH 2/4] Bug 878020 - Add inner shadows to the tab overflow container. r=MattN --- browser/themes/linux/jar.mn | 1 + browser/themes/osx/jar.mn | 2 + .../osx/tabbrowser/tab-overflow-shadow@2x.png | Bin 0 -> 462 bytes .../shared/tabbrowser/tab-overflow-shadow.png | Bin 0 -> 253 bytes browser/themes/shared/tabs.inc.css | 61 ++++++++++++++++++ browser/themes/windows/jar.mn | 2 + toolkit/content/widgets/scrollbox.xml | 41 ++++++++++-- 7 files changed, 101 insertions(+), 6 deletions(-) create mode 100644 browser/themes/osx/tabbrowser/tab-overflow-shadow@2x.png create mode 100644 browser/themes/shared/tabbrowser/tab-overflow-shadow.png diff --git a/browser/themes/linux/jar.mn b/browser/themes/linux/jar.mn index 91abe3af0334..3565198deafb 100644 --- a/browser/themes/linux/jar.mn +++ b/browser/themes/linux/jar.mn @@ -158,6 +158,7 @@ browser.jar: skin/classic/browser/tabbrowser/tab-background-middle.png (tabbrowser/tab-background-middle.png) skin/classic/browser/tabbrowser/tab-background-start.png (tabbrowser/tab-background-start.png) skin/classic/browser/tabbrowser/tab-overflow-border.png (tabbrowser/tab-overflow-border.png) + skin/classic/browser/tabbrowser/tab-overflow-shadow.png (../shared/tabbrowser/tab-overflow-shadow.png) # NOTE: The following two files (tab-selected-end.svg, tab-selected-start.svg) get pre-processed in # Makefile.in with a non-default marker of "%" and the result of that gets packaged. diff --git a/browser/themes/osx/jar.mn b/browser/themes/osx/jar.mn index 40e340be1239..abf84e045729 100644 --- a/browser/themes/osx/jar.mn +++ b/browser/themes/osx/jar.mn @@ -268,6 +268,8 @@ browser.jar: skin/classic/browser/tabbrowser/tab-background-middle@2x.png (tabbrowser/tab-background-middle@2x.png) 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) + skin/classic/browser/tabbrowser/tab-overflow-shadow.png (../shared/tabbrowser/tab-overflow-shadow.png) + skin/classic/browser/tabbrowser/tab-overflow-shadow@2x.png (tabbrowser/tab-overflow-shadow@2x.png) # NOTE: The following two files (tab-selected-end.svg, tab-selected-start.svg) get pre-processed in # Makefile.in with a non-default marker of "%" and the result of that gets packaged. diff --git a/browser/themes/osx/tabbrowser/tab-overflow-shadow@2x.png b/browser/themes/osx/tabbrowser/tab-overflow-shadow@2x.png new file mode 100644 index 0000000000000000000000000000000000000000..b225c581daae3eb0d6808a6ab415aa0165cb1c06 GIT binary patch literal 462 zcmV;<0WtoGP)igS*F3GlrLV(6mEh1C6qC_0B38aEFvpdnM87hkf>{e|6dC+hWcu3r9X6Q zAjfiBP@)D288ja%!PU@t2?UW~(%@m@AgT$#xy7T1tC3U5kfmV$;tsaPQV~mpCn*Xj zD7iO=H=%Kt1lInH{P7;Xu+XJHh3cz1SBwlxqNoW6(t zjfKbSdl&Zb5AxpLZz8qiM9YuVPKEg$^p)Va{a#1<2UIK|-$M|^$N&HU07*qoM6N<$ Ef`FyaHUIzs literal 0 HcmV?d00001 diff --git a/browser/themes/shared/tabbrowser/tab-overflow-shadow.png b/browser/themes/shared/tabbrowser/tab-overflow-shadow.png new file mode 100644 index 0000000000000000000000000000000000000000..3622e2040145599ea1e57ea41d69526ee689327e GIT binary patch literal 253 zcmVkR?YEXCD<-DSXu+qG4e{! zcI>-F#-J})bDUl5RpU6i@PICtkmI^6UsV0i;I73|U6#KY7nhg$i}$i`7Q1<7U~%sZ zBvT{1+{mvypbOigkOq#i$RpYk5U)GJ?#*^U>>tn)q9^0*Zdq=F9S)47 zR?e*8P2mLd!4y298!TEmKHNyT3OT?QKuQqH0_6MvbXpSvY{1)B00000NkvXXu0mjf DDq?9= literal 0 HcmV?d00001 diff --git a/browser/themes/shared/tabs.inc.css b/browser/themes/shared/tabs.inc.css index 1dbcc9949816..d15453e70f94 100644 --- a/browser/themes/shared/tabs.inc.css +++ b/browser/themes/shared/tabs.inc.css @@ -4,6 +4,11 @@ * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ %endif +%ifdef XP_WIN +%define tabbrowserScrollbuttonWidth 22px +%else +%define tabbrowserScrollbuttonWidth 23px +%endif %define tabHeight 31px %define tabCurveWidth 30px %define tabCurveHalfWidth 15px @@ -113,6 +118,62 @@ -moz-padding-start: @tabCurveHalfWidth@; } +/* Tab Overflow */ +.tabbrowser-arrowscrollbox[overflow=true] { + position: relative; +} + +.tabbrowser-arrowscrollbox[overflow=true]::before, +.tabbrowser-arrowscrollbox[overflow=true]::after { + background-image: url(chrome://browser/skin/tabbrowser/tab-overflow-shadow.png); + background-repeat: no-repeat; + background-size: auto 100%; + content: ""; + display: -moz-box; + height: calc(100% - @tabToolbarNavbarOverlap@); + pointer-events: none; + position: absolute; + width: 12px; + /* Make sure the shadow isn't hidden behind the tabs */ + z-index: 3; +} + +%ifdef XP_MACOSX +@media (min-resolution: 2dppx) { + .tabbrowser-arrowscrollbox[overflow=true]::before, + .tabbrowser-arrowscrollbox[overflow=true]::after { + background-image: url(chrome://browser/skin/tabbrowser/tab-overflow-shadow@2x.png); + } +} +%endif + +.scrollbutton-up > .toolbarbutton-icon, +.scrollbutton-down > .toolbarbutton-icon, +.tabbrowser-arrowscrollbox[overflow=true]::before, +.tabbrowser-arrowscrollbox[overflow=true]::after { + transition: opacity 150ms ease; +} + +.tabbrowser-arrowscrollbox[overflow=true][scrollbutton-up-disabled=true]:-moz-locale-dir(ltr)::before, +.tabbrowser-arrowscrollbox[overflow=true][scrollbutton-down-disabled=true]:-moz-locale-dir(ltr)::after, +.tabbrowser-arrowscrollbox[overflow=true][scrollbutton-down-disabled=true]:-moz-locale-dir(rtl)::before, +.tabbrowser-arrowscrollbox[overflow=true][scrollbutton-up-disabled=true]:-moz-locale-dir(rtl)::after { + opacity: 0; +} + +.tabbrowser-arrowscrollbox[overflow=true]::before { + left: 0; + /* Offset the shadow by the width of the scrollbutton so it's on the inside of the buttons. */ + margin-left: @tabbrowserScrollbuttonWidth@; +} + +.tabbrowser-arrowscrollbox[overflow=true]::after { + right: 0; + /* Offset the shadow by the width of the scrollbutton so it's on the inside of the buttons. */ + margin-right: @tabbrowserScrollbuttonWidth@; + transform: scaleX(-1); +} + .tab-background-start[selected=true]::after, .tab-background-start[selected=true]::before, .tab-background-start, diff --git a/browser/themes/windows/jar.mn b/browser/themes/windows/jar.mn index a92a54772161..a92e3d4b6a86 100644 --- a/browser/themes/windows/jar.mn +++ b/browser/themes/windows/jar.mn @@ -187,6 +187,7 @@ browser.jar: skin/classic/browser/tabbrowser/tab-background-middle.png (tabbrowser/tab-background-middle.png) skin/classic/browser/tabbrowser/tab-background-end.png (tabbrowser/tab-background-end.png) skin/classic/browser/tabbrowser/tab-overflow-border.png (tabbrowser/tab-overflow-border.png) + skin/classic/browser/tabbrowser/tab-overflow-shadow.png (../shared/tabbrowser/tab-overflow-shadow.png) # NOTE: The following two files (tab-selected-end.svg, tab-selected-start.svg) get pre-processed in # Makefile.in with a non-default marker of "%" and the result of that gets packaged. @@ -536,6 +537,7 @@ browser.jar: skin/classic/aero/browser/tabbrowser/tab-background-middle.png (tabbrowser/tab-background-middle.png) skin/classic/aero/browser/tabbrowser/tab-background-end.png (tabbrowser/tab-background-end.png) skin/classic/aero/browser/tabbrowser/tab-overflow-border.png (tabbrowser/tab-overflow-border.png) + skin/classic/aero/browser/tabbrowser/tab-overflow-shadow.png (../shared/tabbrowser/tab-overflow-shadow.png) # NOTE: The following two files (tab-selected-end.svg, tab-selected-start.svg) get pre-processed in # Makefile.in with a non-default marker of "%" and the result of that gets packaged. diff --git a/toolkit/content/widgets/scrollbox.xml b/toolkit/content/widgets/scrollbox.xml index 88f3df4e5037..7eee56674014 100644 --- a/toolkit/content/widgets/scrollbox.xml +++ b/toolkit/content/widgets/scrollbox.xml @@ -28,7 +28,7 @@ @@ -184,6 +184,31 @@ ]]> + + + + + + + + + @@ -535,6 +560,8 @@ return; } + this.removeAttribute("overflow"); + this._scrollButtonUp.collapsed = true; this._scrollButtonDown.collapsed = true; try { @@ -569,6 +596,8 @@ return; } + this.setAttribute("overflow", "true"); + this._scrollButtonUp.collapsed = false; this._scrollButtonDown.collapsed = false; try { @@ -599,7 +628,7 @@ Date: Sat, 5 Apr 2014 15:43:00 -0700 Subject: [PATCH 3/4] Bug 992593 - Remove File->Page setup menu item for other GTK/QT platforms as well. r=gavin --- browser/base/content/browser-menubar.inc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/browser/base/content/browser-menubar.inc b/browser/base/content/browser-menubar.inc index e3d468d2400e..de379b0eadb2 100644 --- a/browser/base/content/browser-menubar.inc +++ b/browser/base/content/browser-menubar.inc @@ -73,7 +73,7 @@ accesskey="&emailPageCmd.accesskey;" command="Browser:SendLink"/> -#ifndef XP_LINUX +#if !defined(MOZ_WIDGET_GTK) && !defined(MOZ_WIDGET_QT) Date: Sun, 6 Apr 2014 15:29:25 -0700 Subject: [PATCH 4/4] Backout 5e4eaa3891be due to b-c failures in browser_removeTabsToTheEnd.js --- browser/themes/linux/jar.mn | 1 - browser/themes/osx/jar.mn | 2 - .../osx/tabbrowser/tab-overflow-shadow@2x.png | Bin 462 -> 0 bytes .../shared/tabbrowser/tab-overflow-shadow.png | Bin 253 -> 0 bytes browser/themes/shared/tabs.inc.css | 61 ------------------ browser/themes/windows/jar.mn | 2 - toolkit/content/widgets/scrollbox.xml | 41 ++---------- 7 files changed, 6 insertions(+), 101 deletions(-) delete mode 100644 browser/themes/osx/tabbrowser/tab-overflow-shadow@2x.png delete mode 100644 browser/themes/shared/tabbrowser/tab-overflow-shadow.png diff --git a/browser/themes/linux/jar.mn b/browser/themes/linux/jar.mn index 3565198deafb..91abe3af0334 100644 --- a/browser/themes/linux/jar.mn +++ b/browser/themes/linux/jar.mn @@ -158,7 +158,6 @@ browser.jar: skin/classic/browser/tabbrowser/tab-background-middle.png (tabbrowser/tab-background-middle.png) skin/classic/browser/tabbrowser/tab-background-start.png (tabbrowser/tab-background-start.png) skin/classic/browser/tabbrowser/tab-overflow-border.png (tabbrowser/tab-overflow-border.png) - skin/classic/browser/tabbrowser/tab-overflow-shadow.png (../shared/tabbrowser/tab-overflow-shadow.png) # NOTE: The following two files (tab-selected-end.svg, tab-selected-start.svg) get pre-processed in # Makefile.in with a non-default marker of "%" and the result of that gets packaged. diff --git a/browser/themes/osx/jar.mn b/browser/themes/osx/jar.mn index abf84e045729..40e340be1239 100644 --- a/browser/themes/osx/jar.mn +++ b/browser/themes/osx/jar.mn @@ -268,8 +268,6 @@ browser.jar: skin/classic/browser/tabbrowser/tab-background-middle@2x.png (tabbrowser/tab-background-middle@2x.png) 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) - skin/classic/browser/tabbrowser/tab-overflow-shadow.png (../shared/tabbrowser/tab-overflow-shadow.png) - skin/classic/browser/tabbrowser/tab-overflow-shadow@2x.png (tabbrowser/tab-overflow-shadow@2x.png) # NOTE: The following two files (tab-selected-end.svg, tab-selected-start.svg) get pre-processed in # Makefile.in with a non-default marker of "%" and the result of that gets packaged. diff --git a/browser/themes/osx/tabbrowser/tab-overflow-shadow@2x.png b/browser/themes/osx/tabbrowser/tab-overflow-shadow@2x.png deleted file mode 100644 index b225c581daae3eb0d6808a6ab415aa0165cb1c06..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 462 zcmV;<0WtoGP)igS*F3GlrLV(6mEh1C6qC_0B38aEFvpdnM87hkf>{e|6dC+hWcu3r9X6Q zAjfiBP@)D288ja%!PU@t2?UW~(%@m@AgT$#xy7T1tC3U5kfmV$;tsaPQV~mpCn*Xj zD7iO=H=%Kt1lInH{P7;Xu+XJHh3cz1SBwlxqNoW6(t zjfKbSdl&Zb5AxpLZz8qiM9YuVPKEg$^p)Va{a#1<2UIK|-$M|^$N&HU07*qoM6N<$ Ef`FyaHUIzs diff --git a/browser/themes/shared/tabbrowser/tab-overflow-shadow.png b/browser/themes/shared/tabbrowser/tab-overflow-shadow.png deleted file mode 100644 index 3622e2040145599ea1e57ea41d69526ee689327e..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 253 zcmVkR?YEXCD<-DSXu+qG4e{! zcI>-F#-J})bDUl5RpU6i@PICtkmI^6UsV0i;I73|U6#KY7nhg$i}$i`7Q1<7U~%sZ zBvT{1+{mvypbOigkOq#i$RpYk5U)GJ?#*^U>>tn)q9^0*Zdq=F9S)47 zR?e*8P2mLd!4y298!TEmKHNyT3OT?QKuQqH0_6MvbXpSvY{1)B00000NkvXXu0mjf DDq?9= diff --git a/browser/themes/shared/tabs.inc.css b/browser/themes/shared/tabs.inc.css index d15453e70f94..1dbcc9949816 100644 --- a/browser/themes/shared/tabs.inc.css +++ b/browser/themes/shared/tabs.inc.css @@ -4,11 +4,6 @@ * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ %endif -%ifdef XP_WIN -%define tabbrowserScrollbuttonWidth 22px -%else -%define tabbrowserScrollbuttonWidth 23px -%endif %define tabHeight 31px %define tabCurveWidth 30px %define tabCurveHalfWidth 15px @@ -118,62 +113,6 @@ -moz-padding-start: @tabCurveHalfWidth@; } -/* Tab Overflow */ -.tabbrowser-arrowscrollbox[overflow=true] { - position: relative; -} - -.tabbrowser-arrowscrollbox[overflow=true]::before, -.tabbrowser-arrowscrollbox[overflow=true]::after { - background-image: url(chrome://browser/skin/tabbrowser/tab-overflow-shadow.png); - background-repeat: no-repeat; - background-size: auto 100%; - content: ""; - display: -moz-box; - height: calc(100% - @tabToolbarNavbarOverlap@); - pointer-events: none; - position: absolute; - width: 12px; - /* Make sure the shadow isn't hidden behind the tabs */ - z-index: 3; -} - -%ifdef XP_MACOSX -@media (min-resolution: 2dppx) { - .tabbrowser-arrowscrollbox[overflow=true]::before, - .tabbrowser-arrowscrollbox[overflow=true]::after { - background-image: url(chrome://browser/skin/tabbrowser/tab-overflow-shadow@2x.png); - } -} -%endif - -.scrollbutton-up > .toolbarbutton-icon, -.scrollbutton-down > .toolbarbutton-icon, -.tabbrowser-arrowscrollbox[overflow=true]::before, -.tabbrowser-arrowscrollbox[overflow=true]::after { - transition: opacity 150ms ease; -} - -.tabbrowser-arrowscrollbox[overflow=true][scrollbutton-up-disabled=true]:-moz-locale-dir(ltr)::before, -.tabbrowser-arrowscrollbox[overflow=true][scrollbutton-down-disabled=true]:-moz-locale-dir(ltr)::after, -.tabbrowser-arrowscrollbox[overflow=true][scrollbutton-down-disabled=true]:-moz-locale-dir(rtl)::before, -.tabbrowser-arrowscrollbox[overflow=true][scrollbutton-up-disabled=true]:-moz-locale-dir(rtl)::after { - opacity: 0; -} - -.tabbrowser-arrowscrollbox[overflow=true]::before { - left: 0; - /* Offset the shadow by the width of the scrollbutton so it's on the inside of the buttons. */ - margin-left: @tabbrowserScrollbuttonWidth@; -} - -.tabbrowser-arrowscrollbox[overflow=true]::after { - right: 0; - /* Offset the shadow by the width of the scrollbutton so it's on the inside of the buttons. */ - margin-right: @tabbrowserScrollbuttonWidth@; - transform: scaleX(-1); -} - .tab-background-start[selected=true]::after, .tab-background-start[selected=true]::before, .tab-background-start, diff --git a/browser/themes/windows/jar.mn b/browser/themes/windows/jar.mn index a92e3d4b6a86..a92a54772161 100644 --- a/browser/themes/windows/jar.mn +++ b/browser/themes/windows/jar.mn @@ -187,7 +187,6 @@ browser.jar: skin/classic/browser/tabbrowser/tab-background-middle.png (tabbrowser/tab-background-middle.png) skin/classic/browser/tabbrowser/tab-background-end.png (tabbrowser/tab-background-end.png) skin/classic/browser/tabbrowser/tab-overflow-border.png (tabbrowser/tab-overflow-border.png) - skin/classic/browser/tabbrowser/tab-overflow-shadow.png (../shared/tabbrowser/tab-overflow-shadow.png) # NOTE: The following two files (tab-selected-end.svg, tab-selected-start.svg) get pre-processed in # Makefile.in with a non-default marker of "%" and the result of that gets packaged. @@ -537,7 +536,6 @@ browser.jar: skin/classic/aero/browser/tabbrowser/tab-background-middle.png (tabbrowser/tab-background-middle.png) skin/classic/aero/browser/tabbrowser/tab-background-end.png (tabbrowser/tab-background-end.png) skin/classic/aero/browser/tabbrowser/tab-overflow-border.png (tabbrowser/tab-overflow-border.png) - skin/classic/aero/browser/tabbrowser/tab-overflow-shadow.png (../shared/tabbrowser/tab-overflow-shadow.png) # NOTE: The following two files (tab-selected-end.svg, tab-selected-start.svg) get pre-processed in # Makefile.in with a non-default marker of "%" and the result of that gets packaged. diff --git a/toolkit/content/widgets/scrollbox.xml b/toolkit/content/widgets/scrollbox.xml index 7eee56674014..88f3df4e5037 100644 --- a/toolkit/content/widgets/scrollbox.xml +++ b/toolkit/content/widgets/scrollbox.xml @@ -28,7 +28,7 @@ @@ -184,31 +184,6 @@ ]]> - - - - - - - - - @@ -560,8 +535,6 @@ return; } - this.removeAttribute("overflow"); - this._scrollButtonUp.collapsed = true; this._scrollButtonDown.collapsed = true; try { @@ -596,8 +569,6 @@ return; } - this.setAttribute("overflow", "true"); - this._scrollButtonUp.collapsed = false; this._scrollButtonDown.collapsed = false; try { @@ -628,7 +599,7 @@