mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-19 16:25:38 +00:00
Bug 1664274 - Call SetDocCurrentStateObj for session history in the parent too. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D89812
This commit is contained in:
parent
57fd870466
commit
cca834e53b
@ -5452,14 +5452,18 @@ nsresult nsDocShell::Embed(nsIContentViewer* aContentViewer,
|
||||
NS_ENSURE_SUCCESS(rv, rv);
|
||||
|
||||
// XXX What if SetupNewViewer fails?
|
||||
if (StaticPrefs::fission_sessionHistoryInParent() ? !!mLoadingEntry
|
||||
: !!mLSHE) {
|
||||
// Set history.state
|
||||
SetDocCurrentStateObj(mLSHE,
|
||||
mLoadingEntry ? &mLoadingEntry->mInfo : nullptr);
|
||||
}
|
||||
|
||||
if (mLSHE) {
|
||||
// Restore the editing state, if it's stored in session history.
|
||||
if (mLSHE->HasDetachedEditor()) {
|
||||
ReattachEditorToWindow(mLSHE);
|
||||
}
|
||||
// Set history.state
|
||||
SetDocCurrentStateObj(mLSHE,
|
||||
mLoadingEntry ? &mLoadingEntry->mInfo : nullptr);
|
||||
|
||||
SetHistoryEntryAndUpdateBC(Nothing(), Some<nsISHEntry*>(mLSHE));
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user