Convert ViewHostMsg_DocumentAvailableInMainFrame to use blink LocalFrameHost
This CL changes ViewHostMsg_DocumentAvailableInMainFrame so that it
is implemented in the LocalFrameHost interface and it moves
DocumentAvailableInMainFrame() from RenderViewHostDelegate
to RenderFrameHostDelegate.
Bug: 1043758
Change-Id: I23d727cb39bf98b2b7412b92dc04d139fef3fa27
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2016762
Reviewed-by: Kinuko Yasuda <[email protected]>
Reviewed-by: Dave Tapuska <[email protected]>
Commit-Queue: Julie Kim <[email protected]>
Cr-Commit-Position: refs/heads/master@{#736241}
diff --git a/content/browser/web_contents/web_contents_impl.cc b/content/browser/web_contents/web_contents_impl.cc
index 2f26258..ea2e52b 100644
--- a/content/browser/web_contents/web_contents_impl.cc
+++ b/content/browser/web_contents/web_contents_impl.cc
@@ -4696,6 +4696,11 @@
controller_.ssl_manager()->DidContainInsecureFormAction();
}
+void WebContentsImpl::DocumentAvailableInMainFrame() {
+ for (auto& observer : observers_)
+ observer.DocumentAvailableInMainFrame();
+}
+
void WebContentsImpl::OnDidRunInsecureContent(RenderFrameHostImpl* source,
const GURL& security_origin,
const GURL& target_url) {
@@ -6198,12 +6203,6 @@
UpdateTitleForEntry(entry, title);
}
-void WebContentsImpl::DocumentAvailableInMainFrame(
- RenderViewHost* render_view_host) {
- for (auto& observer : observers_)
- observer.DocumentAvailableInMainFrame();
-}
-
void WebContentsImpl::RouteCloseEvent(RenderViewHost* rvh) {
// Tell the active RenderViewHost to run unload handlers and close, as long
// as the request came from a RenderViewHost in the same BrowsingInstance.