Fix JavaScript alerts from frames with oopif on, after a cross-process click.
BUG=453893,593482
TEST=as in bug
CQ_INCLUDE_TRYBOTS=tryserver.chromium.linux:linux_site_isolation
Review URL: https://codereview.chromium.org/1849013004
Cr-Commit-Position: refs/heads/master@{#386158}
diff --git a/content/renderer/render_frame_impl.h b/content/renderer/render_frame_impl.h
index 597be016..1e25e6e11 100644
--- a/content/renderer/render_frame_impl.h
+++ b/content/renderer/render_frame_impl.h
@@ -802,6 +802,7 @@
const blink::WebFindOptions& options);
void OnStopFinding(StopFindAction action);
void OnEnableViewSourceMode();
+ void OnSuppressFurtherDialogs();
#if defined(OS_ANDROID)
void OnActivateNearestFindResult(int request_id, float x, float y);
void OnFindMatchRects(int current_version);
@@ -1206,6 +1207,11 @@
// Whether or not this RenderFrame is currently pasting.
bool is_pasting_;
+ // Whether we must stop creating nested message loops for modal dialogs. This
+ // is necessary because modal dialogs have a ScopedPageLoadDeferrer on the
+ // stack that interferes with swapping out.
+ bool suppress_further_dialogs_;
+
#if defined(ENABLE_WEBVR)
// The VR dispatcher attached to the frame, lazily initialized.
scoped_ptr<VRDispatcher> vr_dispatcher_;