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

Unified Diff: chrome/browser/ui/cocoa/browser_window_cocoa.mm

Issue 13845022: Mac: Display a native bubble (instead of the JS one) after the web signin flow. (branched from http… (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@ntpBubble
Patch Set: Ditto Created 7 years, 8 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
Index: chrome/browser/ui/cocoa/browser_window_cocoa.mm
diff --git a/chrome/browser/ui/cocoa/browser_window_cocoa.mm b/chrome/browser/ui/cocoa/browser_window_cocoa.mm
index ccb0abbe93f3a621b9e6970fe90fb90c7db48f9c..fdb36eb5ef2b856a379efb6114118b8393ace19b 100644
--- a/chrome/browser/ui/cocoa/browser_window_cocoa.mm
+++ b/chrome/browser/ui/cocoa/browser_window_cocoa.mm
@@ -486,15 +486,18 @@ void BrowserWindowCocoa::ShowOneClickSigninBubble(
const string16& email,
const string16& error_message,
const StartSyncCallback& start_sync_callback) {
+ WebContents* web_contents =
+ browser_->tab_strip_model()->GetActiveWebContents();
if (type == ONE_CLICK_SIGNIN_BUBBLE_TYPE_BUBBLE) {
scoped_nsobject<OneClickSigninBubbleController> bubble_controller(
[[OneClickSigninBubbleController alloc]
initWithBrowserWindowController:cocoa_controller()
+ webContents:web_contents
+ errorMessage:base::SysUTF16ToNSString(
+ error_message)
callback:start_sync_callback]);
[bubble_controller showWindow:nil];
} else {
- WebContents* web_contents =
- browser_->tab_strip_model()->GetActiveWebContents();
// Deletes itself when the dialog closes.
new OneClickSigninDialogController(web_contents, start_sync_callback);
}
« no previous file with comments | « chrome/app/nibs/OneClickSigninBubble.xib ('k') | chrome/browser/ui/cocoa/one_click_signin_bubble_controller.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698