зеркало из https://github.com/mozilla/gecko-dev.git
Bug 776773 - put tabs in the title bar before updating the tab strip. r=ttaubert
This commit is contained in:
Родитель
68761b3c9a
Коммит
90ed48aad7
|
@ -4681,15 +4681,9 @@ var TabsInTitlebar = {
|
||||||
this._readPref();
|
this._readPref();
|
||||||
Services.prefs.addObserver(this._prefName, this, false);
|
Services.prefs.addObserver(this._prefName, this, false);
|
||||||
|
|
||||||
// Don't trust the initial value of the sizemode attribute; wait for the resize event.
|
// Don't trust the initial value of the sizemode attribute; wait for
|
||||||
|
// the resize event (handled in tabbrowser.xml).
|
||||||
this.allowedBy("sizemode", false);
|
this.allowedBy("sizemode", false);
|
||||||
window.addEventListener("resize", function (event) {
|
|
||||||
if (event.target != window)
|
|
||||||
return;
|
|
||||||
let sizemode = document.documentElement.getAttribute("sizemode");
|
|
||||||
TabsInTitlebar.allowedBy("sizemode",
|
|
||||||
sizemode == "maximized" || sizemode == "fullscreen");
|
|
||||||
}, false);
|
|
||||||
|
|
||||||
this._initialized = true;
|
this._initialized = true;
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -3092,6 +3092,11 @@
|
||||||
case "resize":
|
case "resize":
|
||||||
if (aEvent.target != window)
|
if (aEvent.target != window)
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
let sizemode = document.documentElement.getAttribute("sizemode");
|
||||||
|
TabsInTitlebar.allowedBy("sizemode",
|
||||||
|
sizemode == "maximized" || sizemode == "fullscreen");
|
||||||
|
|
||||||
var width = this.mTabstrip.boxObject.width;
|
var width = this.mTabstrip.boxObject.width;
|
||||||
if (width != this.mTabstripWidth) {
|
if (width != this.mTabstripWidth) {
|
||||||
this.adjustTabstrip();
|
this.adjustTabstrip();
|
||||||
|
@ -3099,6 +3104,7 @@
|
||||||
this._handleTabSelect();
|
this._handleTabSelect();
|
||||||
this.mTabstripWidth = width;
|
this.mTabstripWidth = width;
|
||||||
}
|
}
|
||||||
|
|
||||||
this.tabbrowser.updateWindowResizers();
|
this.tabbrowser.updateWindowResizers();
|
||||||
break;
|
break;
|
||||||
case "mouseout":
|
case "mouseout":
|
||||||
|
|
Загрузка…
Ссылка в новой задаче