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

Unified Diff: content/browser/web_contents/web_contents_impl.cc

Issue 753173002: Preparation steps for adding speculative renderer creation. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Address a new round of CR comments: renames, comments and minor changes. Created 6 years, 1 month 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/web_contents/web_contents_impl.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/web_contents/web_contents_impl.cc
diff --git a/content/browser/web_contents/web_contents_impl.cc b/content/browser/web_contents/web_contents_impl.cc
index 7ab54bf0cab318432f04509f45773d236b9ffafb..f67ed2a66bec83aa454182bff36a0b11d361e702 100644
--- a/content/browser/web_contents/web_contents_impl.cc
+++ b/content/browser/web_contents/web_contents_impl.cc
@@ -3908,10 +3908,13 @@ WebPreferences WebContentsImpl::ComputeWebkitPrefs() {
int WebContentsImpl::CreateSwappedOutRenderView(
SiteInstance* instance) {
- return GetRenderManager()->CreateRenderFrame(
- instance, MSG_ROUTING_NONE, CREATE_RF_SWAPPED_OUT |
- CREATE_RF_FOR_MAIN_FRAME_NAVIGATION |
- CREATE_RF_HIDDEN);
+ int render_view_routing_id = MSG_ROUTING_NONE;
+ GetRenderManager()->CreateRenderFrame(
+ instance, nullptr, MSG_ROUTING_NONE,
+ CREATE_RF_SWAPPED_OUT | CREATE_RF_FOR_MAIN_FRAME_NAVIGATION |
+ CREATE_RF_HIDDEN,
+ &render_view_routing_id);
+ return render_view_routing_id;
}
void WebContentsImpl::OnUserGesture() {
@@ -4083,17 +4086,22 @@ int WebContentsImpl::CreateOpenerRenderViews(SiteInstance* instance) {
// Create a swapped out RenderView in the given SiteInstance if none exists,
// setting its opener to the given route_id. Return the new view's route_id.
- return GetRenderManager()->CreateRenderFrame(
- instance, opener_route_id, CREATE_RF_FOR_MAIN_FRAME_NAVIGATION |
- CREATE_RF_SWAPPED_OUT | CREATE_RF_HIDDEN);
+ int render_view_routing_id = MSG_ROUTING_NONE;
+ GetRenderManager()->CreateRenderFrame(instance, nullptr, opener_route_id,
+ CREATE_RF_FOR_MAIN_FRAME_NAVIGATION |
+ CREATE_RF_SWAPPED_OUT |
+ CREATE_RF_HIDDEN,
+ &render_view_routing_id);
+ return render_view_routing_id;
}
NavigationControllerImpl& WebContentsImpl::GetControllerForRenderManager() {
return GetController();
}
-WebUIImpl* WebContentsImpl::CreateWebUIForRenderManager(const GURL& url) {
- return static_cast<WebUIImpl*>(CreateWebUI(url));
+scoped_ptr<WebUIImpl> WebContentsImpl::CreateWebUIForRenderManager(
+ const GURL& url) {
+ return scoped_ptr<WebUIImpl>(static_cast<WebUIImpl*>(CreateWebUI(url)));
}
NavigationEntry*
« no previous file with comments | « content/browser/web_contents/web_contents_impl.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698