Bug 1930654 - Convert _gBrowser to a modern JS class. r=tabbrowser-reviewers,jswinarton

Differential Revision: https://phabricator.services.mozilla.com/D228667
This commit is contained in:
Dão Gottwald 2024-11-14 16:33:19 +00:00
parent a892c69c16
commit c834ce0cb8
3 changed files with 267 additions and 283 deletions

View File

@ -132,8 +132,7 @@ var gBrowserInit = {
.getInterface(Ci.nsIAppWindow).XULBrowserWindow = window.XULBrowserWindow;
window.browserDOMWindow = new nsBrowserAccess();
gBrowser = window._gBrowser;
delete window._gBrowser;
gBrowser = new window.Tabbrowser();
gBrowser.init();
BrowserWindowTracker.track(window);

File diff suppressed because it is too large Load Diff

View File

@ -44,7 +44,7 @@ add_task(async function () {
// Delete getTabDialogBox from gBrowser, to test the fallback to the standalone
// application chooser window.
let _getTabDialogBox = gBrowser.getTabDialogBox;
delete gBrowser.getTabDialogBox;
gBrowser.getTabDialogBox = null;
let appChooserDialogOpenPromise = BrowserTestUtils.domWindowOpened(
null,