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

Unified Diff: ui/app_list/demo/app_list_demo_views.cc

Issue 1432143002: Track where WebContents are created in order to better understand issue. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 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
Index: ui/app_list/demo/app_list_demo_views.cc
diff --git a/ui/app_list/demo/app_list_demo_views.cc b/ui/app_list/demo/app_list_demo_views.cc
index c13278db36795cb2e9bc95c26c9f2f01dfeaf7c1..6e3b5635fd29e17bf5059bc3cb1b2afbc3b6b739 100644
--- a/ui/app_list/demo/app_list_demo_views.cc
+++ b/ui/app_list/demo/app_list_demo_views.cc
@@ -7,6 +7,7 @@
#include "base/memory/scoped_ptr.h"
#include "base/run_loop.h"
#include "content/public/browser/web_contents.h"
+#include "content/public/browser/web_contents_source.h"
#include "content/public/common/content_switches.h"
#include "ui/app_list/test/app_list_test_model.h"
#include "ui/app_list/test/app_list_test_view_delegate.h"
@@ -95,6 +96,8 @@ views::View* DemoAppListViewDelegate::CreateStartPageWebView(
const gfx::Size& size) {
web_contents_.reset(content::WebContents::Create(
content::WebContents::CreateParams(browser_context_)));
+ WebContentsSource::CreateForWebContentsAndLocation(web_contents_.get(),
+ FROM_HERE);
web_contents_->GetController().LoadURL(GURL("http://www.google.com/"),
content::Referrer(),
ui::PAGE_TRANSITION_AUTO_TOPLEVEL,

Powered by Google App Engine
This is Rietveld 408576698