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

Unified Diff: content/browser/tab_contents/tab_contents_view_helper.cc

Issue 9141035: Move RenderWidgetHost::Init() call up (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 11 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/tab_contents/tab_contents_view_helper.cc
diff --git a/content/browser/tab_contents/tab_contents_view_helper.cc b/content/browser/tab_contents/tab_contents_view_helper.cc
index 75896d3c6bc623159543b40ef119f022b8c9f000..fceb1c823d94812d5c3ef25ab589b33fc60e4ab3 100644
--- a/content/browser/tab_contents/tab_contents_view_helper.cc
+++ b/content/browser/tab_contents/tab_contents_view_helper.cc
@@ -82,6 +82,8 @@ TabContents* TabContentsViewHelper::CreateNewWindow(
params.target_url,
new_contents);
+ // TODO(brettw): It seems bogus to reach into here and initialize the host.
+ new_contents->GetRenderViewHost()->Init();
return new_contents;
}
@@ -100,6 +102,10 @@ RenderWidgetHostView* TabContentsViewHelper::CreateNewWidget(
}
// Save the created widget associated with the route so we can show it later.
pending_widget_views_[route_id] = widget_view;
+
+ // TODO(jamesr): Check if this is bogus. If it's not, remove the
+ // pending_contents_ stuff.
+ widget_host->Init();
return widget_view;
}
@@ -119,8 +125,6 @@ TabContents* TabContentsViewHelper::GetCreatedWindow(int route_id) {
!new_contents->GetRenderViewHost()->view())
return NULL;
- // TODO(brettw): It seems bogus to reach into here and initialize the host.
- new_contents->GetRenderViewHost()->Init();
return new_contents;
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698