mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-24 21:31:04 +00:00
Bug 1261842 - When putting the initial tab into the restored background state, flip it to non-remote. r=mikedeboer
MozReview-Commit-ID: BX8XbYjJHGf --HG-- extra : rebase_source : 5333e1a15e36aaea5e6e38ab7df5919e8cda3017 extra : source : 2a1acfd17baf3a269719c70cdd5b273e8b344b41
This commit is contained in:
parent
ef1514c4ea
commit
13379af1e1
@ -3214,6 +3214,18 @@ var SessionStoreInternal = {
|
||||
let tabbrowser = window.gBrowser;
|
||||
let forceOnDemand = options.forceOnDemand;
|
||||
|
||||
// If the browser we're attempting to restore happens to be
|
||||
// remote, we need to flip it back to non-remote if it's going
|
||||
// to go into the pending background tab state. This is to make
|
||||
// sure that the background tab can't crash if it hasn't yet
|
||||
// been restored. Normally, when a window is restored, the tabs
|
||||
// that SessionStore inserts are non-remote - but the initial
|
||||
// browser is, by default, remote, so this check and flip is
|
||||
// mostly for that case.
|
||||
if (browser.isRemoteBrowser && (!restoreImmediately || forceOnDemand)) {
|
||||
tabbrowser.updateBrowserRemoteness(browser, false);
|
||||
}
|
||||
|
||||
// Increase the busy state counter before modifying the tab.
|
||||
this._setWindowStateBusy(window);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user