Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(96)

Unified Diff: content/renderer/render_view_impl.cc

Issue 964583002: Remove showModalDialog (Chrome side) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: content/renderer/render_view_impl.cc
diff --git a/content/renderer/render_view_impl.cc b/content/renderer/render_view_impl.cc
index f4c0c44c9a64acb15f73923e28548ed5c2a0a7a9..c95981ad4158e70b13e34582b626881af7795e5f 100644
--- a/content/renderer/render_view_impl.cc
+++ b/content/renderer/render_view_impl.cc
@@ -1502,6 +1502,8 @@ bool RenderViewImpl::SendAndRunNestedMessageLoop(IPC::SyncMessage* message) {
// equivalent of WebView::willEnterModalLoop. In the case of showModalDialog
// it is particularly important that we do not call willEnterModalLoop as
// that would defer resource loads for the dialog itself.
+ // TODO(jochen): Now that we no longer support showModalDialog, see if we can
jam 2015/02/26 21:40:36 there are still other callers of this, so there's
+ // simplify this logic.
if (RenderThreadImpl::current()) // Will be NULL during unit tests.
RenderThreadImpl::current()->DoNotNotifyWebKitOfModalLoop();
@@ -2025,28 +2027,6 @@ void RenderViewImpl::show(WebNavigationPolicy policy) {
SetPendingWindowRect(initial_rect_);
}
-void RenderViewImpl::runModal() {
- DCHECK(did_show_) << "should already have shown the view";
-
- // Don't allow further dialogs if we are waiting to swap out, since the
- // PageGroupLoadDeferrer in our stack prevents it.
- if (suppress_dialogs_until_swap_out_)
- return;
-
- // We must keep WebKit's shared timer running in this case in order to allow
- // showModalDialog to function properly.
- //
- // TODO(darin): WebKit should really be smarter about suppressing events and
- // timers so that we do not need to manage the shared timer in such a heavy
- // handed manner.
- //
- if (RenderThreadImpl::current()) // Will be NULL during unit tests.
- RenderThreadImpl::current()->DoNotSuspendWebKitSharedTimer();
-
- SendAndRunNestedMessageLoop(new ViewHostMsg_RunModal(
- routing_id_, opener_id_));
-}
-
bool RenderViewImpl::requestPointerLock() {
return mouse_lock_dispatcher_->LockMouse(webwidget_mouse_lock_target_.get());
}

Powered by Google App Engine
This is Rietveld 408576698