Backed out 2 changesets (bug 1740517, bug 1740516) for causing failures at browser_bug343515.js and browser_browsingContext-webProgress.js. CLOSED TREE

Backed out changeset e656dd82e48a (bug 1740517)
Backed out changeset 9eb7a39f39b7 (bug 1740516)
This commit is contained in:
Butkovits Atila
2021-11-23 23:28:54 +02:00
parent 003eb16923
commit f11c69b446
10 changed files with 6 additions and 238 deletions

View File

@@ -2910,21 +2910,12 @@ void BrowsingContext::DidSet(FieldIndex<IDX_IsInBFCache>) {
nsDocShell::Cast(mDocShell)->MaybeDisconnectChildListenersOnPageHide();
}
if (isInBFCache) {
PreOrderWalk([&](BrowsingContext* aContext) {
nsCOMPtr<nsIDocShell> shell = aContext->GetDocShell();
if (shell) {
nsDocShell::Cast(shell)->FirePageHideShowNonRecursive(false);
}
});
} else {
PostOrderWalk([&](BrowsingContext* aContext) {
nsCOMPtr<nsIDocShell> shell = aContext->GetDocShell();
if (shell) {
nsDocShell::Cast(shell)->FirePageHideShowNonRecursive(true);
}
});
}
PreOrderWalk([&](BrowsingContext* aContext) {
nsCOMPtr<nsIDocShell> shell = aContext->GetDocShell();
if (shell) {
nsDocShell::Cast(shell)->FirePageHideShowNonRecursive(!isInBFCache);
}
});
if (isInBFCache) {
PreOrderWalk([&](BrowsingContext* aContext) {