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

Side by Side Diff: chrome/browser/profiles/profile_window.cc

Issue 856733004: Loading the Launcher with a Locked Profile launched UserManager. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: tapted@: test fixes and remove a const-ref. Created 5 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 | « chrome/browser/profiles/profile_window.h ('k') | chrome/browser/ui/app_list/app_list_service.h » ('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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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/profiles/profile_window.h" 5 #include "chrome/browser/profiles/profile_window.h"
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "base/files/file_path.h" 8 #include "base/files/file_path.h"
9 #include "base/prefs/pref_service.h" 9 #include "base/prefs/pref_service.h"
10 #include "base/strings/string_number_conversions.h" 10 #include "base/strings/string_number_conversions.h"
(...skipping 195 matching lines...) Expand 10 before | Expand all | Expand 10 after
206 page += profiles::kUserManagerSelectProfileTaskManager; 206 page += profiles::kUserManagerSelectProfileTaskManager;
207 } else if (profile_open_action == 207 } else if (profile_open_action ==
208 profiles::USER_MANAGER_SELECT_PROFILE_ABOUT_CHROME) { 208 profiles::USER_MANAGER_SELECT_PROFILE_ABOUT_CHROME) {
209 page += profiles::kUserManagerSelectProfileAboutChrome; 209 page += profiles::kUserManagerSelectProfileAboutChrome;
210 } else if (profile_open_action == 210 } else if (profile_open_action ==
211 profiles::USER_MANAGER_SELECT_PROFILE_CHROME_SETTINGS) { 211 profiles::USER_MANAGER_SELECT_PROFILE_CHROME_SETTINGS) {
212 page += profiles::kUserManagerSelectProfileChromeSettings; 212 page += profiles::kUserManagerSelectProfileChromeSettings;
213 } else if (profile_open_action == 213 } else if (profile_open_action ==
214 profiles::USER_MANAGER_SELECT_PROFILE_CHROME_MEMORY) { 214 profiles::USER_MANAGER_SELECT_PROFILE_CHROME_MEMORY) {
215 page += profiles::kUserManagerSelectProfileChromeMemory; 215 page += profiles::kUserManagerSelectProfileChromeMemory;
216 } else if (profile_open_action ==
217 profiles::USER_MANAGER_SELECT_PROFILE_APP_LAUNCHER) {
218 page += profiles::kUserManagerSelectProfileAppLauncher;
216 } 219 }
217 callback.Run(system_profile, page); 220 callback.Run(system_profile, page);
218 } 221 }
219 222
220 // Updates Chrome services that require notification when 223 // Updates Chrome services that require notification when
221 // the new_profile_management's status changes. 224 // the new_profile_management's status changes.
222 void UpdateServicesWithNewProfileManagementFlag(Profile* profile, 225 void UpdateServicesWithNewProfileManagementFlag(Profile* profile,
223 bool new_flag_status) { 226 bool new_flag_status) {
224 AccountReconcilor* account_reconcilor = 227 AccountReconcilor* account_reconcilor =
225 AccountReconcilorFactory::GetForProfile(profile); 228 AccountReconcilorFactory::GetForProfile(profile);
226 account_reconcilor->OnNewProfileManagementFlagChanged(new_flag_status); 229 account_reconcilor->OnNewProfileManagementFlagChanged(new_flag_status);
227 } 230 }
228 231
229 } // namespace 232 } // namespace
230 233
231 namespace profiles { 234 namespace profiles {
232 235
233 // User Manager parameters are prefixed with hash. 236 // User Manager parameters are prefixed with hash.
234 const char kUserManagerDisplayTutorial[] = "#tutorial"; 237 const char kUserManagerDisplayTutorial[] = "#tutorial";
235 const char kUserManagerSelectProfileTaskManager[] = "#task-manager"; 238 const char kUserManagerSelectProfileTaskManager[] = "#task-manager";
236 const char kUserManagerSelectProfileAboutChrome[] = "#about-chrome"; 239 const char kUserManagerSelectProfileAboutChrome[] = "#about-chrome";
237 const char kUserManagerSelectProfileChromeSettings[] = "#chrome-settings"; 240 const char kUserManagerSelectProfileChromeSettings[] = "#chrome-settings";
238 const char kUserManagerSelectProfileChromeMemory[] = "#chrome-memory"; 241 const char kUserManagerSelectProfileChromeMemory[] = "#chrome-memory";
242 const char kUserManagerSelectProfileAppLauncher[] = "#app-launcher";
239 243
240 void FindOrCreateNewWindowForProfile( 244 void FindOrCreateNewWindowForProfile(
241 Profile* profile, 245 Profile* profile,
242 chrome::startup::IsProcessStartup process_startup, 246 chrome::startup::IsProcessStartup process_startup,
243 chrome::startup::IsFirstRun is_first_run, 247 chrome::startup::IsFirstRun is_first_run,
244 chrome::HostDesktopType desktop_type, 248 chrome::HostDesktopType desktop_type,
245 bool always_create) { 249 bool always_create) {
246 #if defined(OS_IOS) 250 #if defined(OS_IOS)
247 NOTREACHED(); 251 NOTREACHED();
248 #else 252 #else
(...skipping 250 matching lines...) Expand 10 before | Expand all | Expand 10 after
499 case BrowserWindow::AVATAR_BUBBLE_MODE_SHOW_ERROR: 503 case BrowserWindow::AVATAR_BUBBLE_MODE_SHOW_ERROR:
500 *bubble_view_mode = BUBBLE_VIEW_MODE_PROFILE_CHOOSER; 504 *bubble_view_mode = BUBBLE_VIEW_MODE_PROFILE_CHOOSER;
501 *tutorial_mode = TUTORIAL_MODE_SHOW_ERROR; 505 *tutorial_mode = TUTORIAL_MODE_SHOW_ERROR;
502 return; 506 return;
503 default: 507 default:
504 *bubble_view_mode = profiles::BUBBLE_VIEW_MODE_PROFILE_CHOOSER; 508 *bubble_view_mode = profiles::BUBBLE_VIEW_MODE_PROFILE_CHOOSER;
505 } 509 }
506 } 510 }
507 511
508 } // namespace profiles 512 } // namespace profiles
OLDNEW
« no previous file with comments | « chrome/browser/profiles/profile_window.h ('k') | chrome/browser/ui/app_list/app_list_service.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698