PlzNavigate: use is_waiting_for_beforeunload_ack in the RenderFrameHost
This CL removes the function IsWaitingForBeforeUnloadACK in favor of just using
the is_waiting_for_beforeunload_ack now that PlzNavigate uses the
BeforeUnload IPC. This CL undoes lots of
the work done in https://codereview.chromium.org/789643005.
BUG=504347
Review URL: https://codereview.chromium.org/1213773003
Cr-Commit-Position: refs/heads/master@{#336543}
diff --git a/content/browser/web_contents/web_contents_impl.cc b/content/browser/web_contents/web_contents_impl.cc
index 2d64c53..5ee8b9c 100644
--- a/content/browser/web_contents/web_contents_impl.cc
+++ b/content/browser/web_contents/web_contents_impl.cc
@@ -3993,7 +3993,7 @@
if (DevToolsAgentHost::IsDebuggerAttached(this))
return;
- if (rfhi->IsWaitingForBeforeUnloadACK() ||
+ if (rfhi->is_waiting_for_beforeunload_ack() ||
rfhi->IsWaitingForUnloadACK()) {
// Hang occurred while firing the beforeunload/unload handler.
// Pretend the handler fired so tab closing continues as if it had.
@@ -4009,7 +4009,7 @@
// close. Otherwise, pretend the unload listeners have all fired and close
// the tab.
bool close = true;
- if (rfhi->IsWaitingForBeforeUnloadACK() && delegate_) {
+ if (rfhi->is_waiting_for_beforeunload_ack() && delegate_) {
delegate_->BeforeUnloadFired(this, true, &close);
}
if (close)