зеркало из https://github.com/mozilla/gecko-dev.git
Bug 575516 - In Fullscreen mode, move caption buttons to top. r=dao a=blocks-blocker
This commit is contained in:
Родитель
40ebd639b4
Коммит
59c286ea47
|
@ -3919,6 +3919,25 @@ var FullScreen = {
|
|||
document.documentElement.setAttribute("inFullscreen", true);
|
||||
}
|
||||
|
||||
// In tabs-on-top mode, move window controls to the tab bar,
|
||||
// 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 ctlsOnTabbar = TabsOnTop.enabled &&
|
||||
!gPrefService.getBoolPref("browser.tabs.autoHide");
|
||||
if (fullscreenctls.parentNode.id == "nav-bar" && ctlsOnTabbar) {
|
||||
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) {
|
||||
document.getElementById("nav-bar").appendChild(fullscreenctls);
|
||||
fullscreenflex.setAttribute("fullscreencontrol", "true");
|
||||
}
|
||||
|
||||
var controls = document.getElementsByAttribute("fullscreencontrol", "true");
|
||||
for (var i = 0; i < controls.length; ++i)
|
||||
controls[i].hidden = aShow;
|
||||
|
|
|
@ -970,6 +970,10 @@ toolbar:not([iconsize="small"])[mode="icons"] #forward-button:not([disabled="tru
|
|||
|
||||
/* ::::: fullscreen window controls ::::: */
|
||||
|
||||
#TabsToolbar > #window-controls {
|
||||
-moz-margin-start: 4px;
|
||||
}
|
||||
|
||||
#minimize-button,
|
||||
#restore-button,
|
||||
#close-button {
|
||||
|
|
Загрузка…
Ссылка в новой задаче