Bug 1520791 - ensure initial browser's docshell is marked as active in the parent, r=mconley
authorGijs Kruitbosch <gijskruitbosch@gmail.com>
Thu, 17 Jan 2019 15:58:36 +0000
changeset 514270 de634684229e8c53ceb03b56dd45e52a1a0af9e1
parent 514269 cc32943d74cc1623f28d6dedd23beabdfbbbf753
child 514271 accc4d418bd11369da1dca52b3ed0ae6d7dea31d
push id1953
push userffxbld-merge
push dateMon, 11 Mar 2019 12:10:20 +0000
treeherdermozilla-release@9c35dcbaa899 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmconley
bugs1520791
milestone66.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1520791 - ensure initial browser's docshell is marked as active in the parent, r=mconley Differential Revision: https://phabricator.services.mozilla.com/D16862
browser/base/content/tabbrowser.js
--- a/browser/base/content/tabbrowser.js
+++ b/browser/base/content/tabbrowser.js
@@ -355,16 +355,20 @@ window._gBrowser = {
       tab.setAttribute("usercontextid", userContextId);
       ContextualIdentityService.setTabStyle(tab);
     }
 
     this._tabForBrowser.set(browser, tab);
 
     this._appendStatusPanel();
 
+    // This is the initial browser, so it's usually active; the default is false
+    // so we have to update it:
+    browser.docShellIsActive = this.shouldActivateDocShell(browser);
+
     // Only necessary because of pageloader talos tests which access this.
     // Bug 1508171 covers removing this.
     this.initialBrowser = browser;
 
     let autoScrollPopup = browser._createAutoScrollPopup();
     autoScrollPopup.id = "autoscroller";
     document.getElementById("mainPopupSet").appendChild(autoScrollPopup);
     browser.setAttribute("autoscrollpopup", autoScrollPopup.id);