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

Unified Diff: content/browser/frame_host/render_frame_host_impl.cc

Issue 2745653011: Fix the browser not being notified when a webview embedder handles a navigation. (Closed)
Patch Set: without PlzNavigate Created 3 years, 9 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
« no previous file with comments | « content/browser/frame_host/render_frame_host_impl.h ('k') | content/common/frame_messages.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/frame_host/render_frame_host_impl.cc
diff --git a/content/browser/frame_host/render_frame_host_impl.cc b/content/browser/frame_host/render_frame_host_impl.cc
index 944d444d2d9d16492223aa0b817f738e1876673d..21d106964de1cdc74c3376a5c1332fa6b8608865 100644
--- a/content/browser/frame_host/render_frame_host_impl.cc
+++ b/content/browser/frame_host/render_frame_host_impl.cc
@@ -755,6 +755,10 @@ bool RenderFrameHostImpl::OnMessageReceived(const IPC::Message &msg) {
IPC_MESSAGE_HANDLER(FrameHostMsg_ShowPopup, OnShowPopup)
IPC_MESSAGE_HANDLER(FrameHostMsg_HidePopup, OnHidePopup)
#endif
+#if defined(OS_ANDROID)
+ IPC_MESSAGE_HANDLER(FrameHostMsg_NavigationHandledByEmbedder,
+ OnNavigationHandledByEmbedder)
+#endif
IPC_MESSAGE_HANDLER(FrameHostMsg_ShowCreatedWindow, OnShowCreatedWindow)
IPC_END_MESSAGE_MAP()
@@ -2264,6 +2268,15 @@ void RenderFrameHostImpl::OnHidePopup() {
}
#endif
+#if defined(OS_ANDROID)
+void RenderFrameHostImpl::OnNavigationHandledByEmbedder() {
+ if (navigation_handle_)
+ navigation_handle_->set_net_error_code(net::ERR_ABORTED);
+
+ OnDidStopLoading();
+}
+#endif
+
void RenderFrameHostImpl::OnShowCreatedWindow(int pending_widget_routing_id,
WindowOpenDisposition disposition,
const gfx::Rect& initial_rect,
« no previous file with comments | « content/browser/frame_host/render_frame_host_impl.h ('k') | content/common/frame_messages.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698