Bug 1296907 - fix 1px offset of private browsing to 'normal' browsing window, r=mstange
authorGijs Kruitbosch <gijskruitbosch@gmail.com>
Mon, 22 Aug 2016 22:52:26 +0100
changeset 341645 e0bffa9456d64902a3d9a5c7a7b82c24ec721d8f
parent 341644 3748b7a5ea35f7e4ea5254234138bbaf46a280a2
child 341646 a759a1704791bd3de6462d4153f02c7844e786b6
push id5
push userfmarier@mozilla.com
push dateFri, 26 Aug 2016 00:45:46 +0000
reviewersmstange
bugs1296907
milestone51.0a1
Bug 1296907 - fix 1px offset of private browsing to 'normal' browsing window, r=mstange MozReview-Commit-ID: 2TkYag9o9Na
browser/base/content/browser.css
browser/themes/osx/devedition.css
--- a/browser/base/content/browser.css
+++ b/browser/base/content/browser.css
@@ -261,16 +261,27 @@ toolbar[customizing] > .overflow-button 
 }
 
 #titlebar-secondary-buttonbox:-moz-locale-dir(rtl),
 #titlebar-buttonbox-container:-moz-locale-dir(ltr),
 .titlebar-placeholder[type="caption-buttons"]:-moz-locale-dir(ltr),
 .titlebar-placeholder[type="fullscreen-button"]:-moz-locale-dir(rtl) {
   -moz-box-ordinal-group: 0;
 }
+
+/* In private windows, the #titlebar-content is higher because of the
+ * private browsing indicator. With the margin-top the titlebar buttons
+ * align to the top correctly in that case, but only if we don't stretch
+ * the box they're in because the container is too high, so we override
+ * the default alignment value (stretch).
+ */
+#main-window[tabsintitlebar] > #titlebar > #titlebar-content > #titlebar-buttonbox-container {
+  -moz-box-align: start;
+}
+
 %else
 /* On non-OSX, these should be start-aligned */
 #titlebar-buttonbox-container {
   -moz-box-align: start;
 }
 %endif
 
 %if !defined(MOZ_WIDGET_GTK)
--- a/browser/themes/osx/devedition.css
+++ b/browser/themes/osx/devedition.css
@@ -27,26 +27,16 @@
 }
 
 /* Resize things so that the native titlebar is in line with the tabs */
 #main-window[tabsintitlebar] > #titlebar > #titlebar-content > #titlebar-buttonbox-container,
 #main-window[tabsintitlebar] > #titlebar > #titlebar-content > #titlebar-secondary-buttonbox > #titlebar-fullscreen-button {
   margin-top: 6px;
 }
 
-/* In private windows, the #titlebar-content is higher because of the
- * private browsing indicator. With the margin-top the titlebar buttons
- * align to the top correctly in that case, but only if we don't stretch
- * the box they're in because the container is too high, so we override
- * the default alignment value (stretch).
- */
-#main-window[tabsintitlebar] > #titlebar > #titlebar-content > #titlebar-buttonbox-container {
-  -moz-box-align: start;
-}
-
 /* Square back and forward buttons.  Need !important on these because there
    are a lot of more specific selectors sprinkled around elsewhere for changing
    background / shadows for different states */
 #back-button,
 #forward-button {
   height: 24px !important;
   box-shadow: none !important;
   border: 1px solid var(--chrome-nav-bar-controls-border-color) !important;