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

Unified Diff: chrome/browser/ui/cocoa/profiles/user_manager_mac.mm

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: chrome/browser/ui/cocoa/profiles/user_manager_mac.mm
diff --git a/chrome/browser/ui/cocoa/profiles/user_manager_mac.mm b/chrome/browser/ui/cocoa/profiles/user_manager_mac.mm
index e5bf1c25d50a7d97f1b32c42156725e7f5967ae0..b671e60f1ff0b78713976f47aec2344297945832 100644
--- a/chrome/browser/ui/cocoa/profiles/user_manager_mac.mm
+++ b/chrome/browser/ui/cocoa/profiles/user_manager_mac.mm
@@ -28,6 +28,7 @@
#include "content/public/browser/render_widget_host_view.h"
#include "content/public/browser/web_contents.h"
#include "content/public/browser/web_contents_delegate.h"
+#include "content/public/browser/web_contents_source.h"
#include "ui/base/l10n/l10n_util_mac.h"
#include "ui/events/keycodes/keyboard_codes.h"
@@ -194,6 +195,8 @@ class ReauthDialogDelegate : public UserManager::ReauthDialogObserver,
reauthWebContents_.reset(content::WebContents::Create(
content::WebContents::CreateParams(profile)));
+ WebContentsSource::CreateForWebContentsAndLocation(reauthWebContents_.get(),
+ FROM_HERE);
window.get().contentView = reauthWebContents_->GetNativeView();
webContentsDelegate_.reset(
new ReauthDialogDelegate(reauthWebContents_.get(), emailAddress_));
@@ -293,6 +296,8 @@ class ReauthDialogDelegate : public UserManager::ReauthDialogObserver,
// Initialize the web view.
webContents_.reset(content::WebContents::Create(
content::WebContents::CreateParams(profile)));
+ WebContentsSource::CreateForWebContentsAndLocation(webContents_.get(),
+ FROM_HERE);
window.contentView = webContents_->GetNativeView();
webContentsDelegate_.reset(new UserManagerWebContentsDelegate());
webContents_->SetDelegate(webContentsDelegate_.get());

Powered by Google App Engine
This is Rietveld 408576698