diff --git a/browser/base/content/browser.js b/browser/base/content/browser.js
index 43af50e5be3..517d127976d 100644
--- a/browser/base/content/browser.js
+++ b/browser/base/content/browser.js
@@ -4413,7 +4413,6 @@ var FullScreen = {
// and in tabs-on-bottom mode, move them back to the navigation toolbar.
// When there is a chance the tab bar may be collapsed, put window
// controls on nav bar.
- var fullscreenflex = document.getElementById("fullscreenflex");
var fullscreenctls = document.getElementById("window-controls");
var navbar = document.getElementById("nav-bar");
var ctlsOnTabbar = window.toolbar.visible &&
@@ -4421,14 +4420,12 @@ var FullScreen = {
(TabsOnTop.enabled &&
!gPrefService.getBoolPref("browser.tabs.autoHide")));
if (fullscreenctls.parentNode == navbar && ctlsOnTabbar) {
+ fullscreenctls.removeAttribute("flex");
document.getElementById("TabsToolbar").appendChild(fullscreenctls);
- // we don't need this space in tabs-on-top mode, so prevent it from
- // being shown
- fullscreenflex.removeAttribute("fullscreencontrol");
}
else if (fullscreenctls.parentNode.id == "TabsToolbar" && !ctlsOnTabbar) {
+ fullscreenctls.setAttribute("flex", "1");
navbar.appendChild(fullscreenctls);
- fullscreenflex.setAttribute("fullscreencontrol", "true");
}
var controls = document.getElementsByAttribute("fullscreencontrol", "true");
diff --git a/browser/base/content/browser.xul b/browser/base/content/browser.xul
index a6549cfc3d8..a0c13684d48 100644
--- a/browser/base/content/browser.xul
+++ b/browser/base/content/browser.xul
@@ -475,7 +475,7 @@
toolbarname="&navbarCmd.label;" accesskey="&navbarCmd.accesskey;"
fullscreentoolbar="true" mode="icons" customizable="true"
iconsize="large"
- defaultset="unified-back-forward-button,urlbar-container,reload-button,stop-button,search-container,home-button,bookmarks-menu-button-container,fullscreenflex,window-controls"
+ defaultset="unified-back-forward-button,urlbar-container,reload-button,stop-button,search-container,home-button,bookmarks-menu-button-container,window-controls"
context="toolbar-context-menu">
-
-
+
diff --git a/browser/components/nsBrowserGlue.js b/browser/components/nsBrowserGlue.js
index 26f20e9c3ec..dd1feb1cac1 100644
--- a/browser/components/nsBrowserGlue.js
+++ b/browser/components/nsBrowserGlue.js
@@ -1243,13 +1243,7 @@ BrowserGlue.prototype = {
// Need to migrate only if toolbar is customized and the element is not found.
if (currentset &&
currentset.indexOf("bookmarks-menu-button-container") == -1) {
- if (currentset.indexOf("fullscreenflex") != -1) {
- currentset = currentset.replace(/(^|,)fullscreenflex($|,)/,
- "$1bookmarks-menu-button-container,fullscreenflex$2")
- }
- else {
- currentset += ",bookmarks-menu-button-container";
- }
+ currentset += ",bookmarks-menu-button-container";
this._setPersist(toolbarResource, currentsetResource, currentset);
}
}
diff --git a/browser/themes/winstripe/browser.css b/browser/themes/winstripe/browser.css
index 5f2d224f419..41c71862673 100644
--- a/browser/themes/winstripe/browser.css
+++ b/browser/themes/winstripe/browser.css
@@ -1148,7 +1148,7 @@ toolbar[mode=full] .toolbarbutton-1 > .toolbarbutton-menubutton-button {
/* ::::: fullscreen window controls ::::: */
-#TabsToolbar > #window-controls {
+#window-controls {
-moz-margin-start: 4px;
}