Backed out changeset ae3db166c985 (bug 1673683) for causing empty pinned tabs with fission (bug 1687616). a=backout DONTBUILD

This commit is contained in:
smolnar 2021-01-20 11:46:11 +02:00
parent 2c06b16a0c
commit b3bcdd2462
3 changed files with 13 additions and 2 deletions

View File

@ -1864,6 +1864,12 @@
aBrowser.droppedLinkHandler = oldDroppedLinkHandler;
// Switching a browser's remoteness will create a new frameLoader.
// As frameLoaders start out with an active docShell we have to
// deactivate it if this is not the selected tab's browser or the
// browser window is minimized.
aBrowser.docShellIsActive = this.shouldActivateDocShell(aBrowser);
// Create a new tab progress listener for the new browser we just injected,
// since tab progress listeners have logic for handling the initial about:blank
// load

View File

@ -167,8 +167,6 @@ void CanonicalBrowsingContext::ReplacedBy(
aNewContext->mWebProgress = std::move(mWebProgress);
aNewContext->mFields.SetWithoutSyncing<IDX_BrowserId>(GetBrowserId());
aNewContext->mFields.SetWithoutSyncing<IDX_HistoryID>(GetHistoryID());
aNewContext->mFields.SetWithoutSyncing<IDX_ExplicitActive>(
GetExplicitActive());
if (mSessionHistory) {
mSessionHistory->SetBrowsingContext(aNewContext);

View File

@ -182,11 +182,18 @@ var ModuleManager = {
this.forEach(module => {
module.onDestroyBrowser();
});
// TODO: Bug 1673683: `docShellIsActive` is sometimes not preserved when
// switching process.
this.docShellIsActiveWhileSwitchingProcess = this.browser.docShellIsActive;
},
didChangeBrowserRemoteness() {
debug`DidChangeBrowserRemoteness`;
this.browser.docShellIsActive = this.docShellIsActiveWhileSwitchingProcess;
this.docShellIsActiveWhileSwitchingProcess = undefined;
this.forEach(module => {
if (module.impl) {
module.impl.onInitBrowser();