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

Side by Side Diff: chrome/browser/printing/print_dialog_cloud.cc

Issue 2687693002: Linux/Windows: Setting focus to the first profile in profile switcher (Closed)
Patch Set: Renaming |focus_first_profile| to |is_source_keyboard| Created 3 years, 10 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 unified diff | Download patch
« no previous file with comments | « no previous file | chrome/browser/signin/chrome_signin_helper.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/printing/print_dialog_cloud.h" 5 #include "chrome/browser/printing/print_dialog_cloud.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/macros.h" 8 #include "base/macros.h"
9 #include "base/threading/thread_task_runner_handle.h" 9 #include "base/threading/thread_task_runner_handle.h"
10 #include "chrome/browser/browser_process.h" 10 #include "chrome/browser/browser_process.h"
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after
70 void CreateCloudPrintSigninTab(Browser* browser, 70 void CreateCloudPrintSigninTab(Browser* browser,
71 bool add_account, 71 bool add_account,
72 const base::Closure& callback) { 72 const base::Closure& callback) {
73 DCHECK_CURRENTLY_ON(content::BrowserThread::UI); 73 DCHECK_CURRENTLY_ON(content::BrowserThread::UI);
74 if (switches::IsEnableAccountConsistency() && 74 if (switches::IsEnableAccountConsistency() &&
75 !browser->profile()->IsOffTheRecord()) { 75 !browser->profile()->IsOffTheRecord()) {
76 browser->window()->ShowAvatarBubbleFromAvatarButton( 76 browser->window()->ShowAvatarBubbleFromAvatarButton(
77 add_account ? BrowserWindow::AVATAR_BUBBLE_MODE_ADD_ACCOUNT 77 add_account ? BrowserWindow::AVATAR_BUBBLE_MODE_ADD_ACCOUNT
78 : BrowserWindow::AVATAR_BUBBLE_MODE_SIGNIN, 78 : BrowserWindow::AVATAR_BUBBLE_MODE_SIGNIN,
79 signin::ManageAccountsParams(), 79 signin::ManageAccountsParams(),
80 signin_metrics::AccessPoint::ACCESS_POINT_CLOUD_PRINT); 80 signin_metrics::AccessPoint::ACCESS_POINT_CLOUD_PRINT, false);
81 } else { 81 } else {
82 GURL url = add_account ? cloud_devices::GetCloudPrintAddAccountURL() 82 GURL url = add_account ? cloud_devices::GetCloudPrintAddAccountURL()
83 : cloud_devices::GetCloudPrintSigninURL(); 83 : cloud_devices::GetCloudPrintSigninURL();
84 content::WebContents* web_contents = 84 content::WebContents* web_contents =
85 browser->OpenURL(content::OpenURLParams( 85 browser->OpenURL(content::OpenURLParams(
86 google_util::AppendGoogleLocaleParam( 86 google_util::AppendGoogleLocaleParam(
87 url, g_browser_process->GetApplicationLocale()), 87 url, g_browser_process->GetApplicationLocale()),
88 content::Referrer(), WindowOpenDisposition::NEW_FOREGROUND_TAB, 88 content::Referrer(), WindowOpenDisposition::NEW_FOREGROUND_TAB,
89 ui::PAGE_TRANSITION_AUTO_BOOKMARK, false)); 89 ui::PAGE_TRANSITION_AUTO_BOOKMARK, false));
90 new SignInObserver(web_contents, callback); 90 new SignInObserver(web_contents, callback);
91 } 91 }
92 } 92 }
93 93
94 } // namespace print_dialog_cloud 94 } // namespace print_dialog_cloud
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/signin/chrome_signin_helper.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698