| OLD | NEW |
| 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 91 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 102 DISALLOW_COPY_AND_ASSIGN(BrowserAddedForProfileObserver); | 102 DISALLOW_COPY_AND_ASSIGN(BrowserAddedForProfileObserver); |
| 103 }; | 103 }; |
| 104 | 104 |
| 105 void OpenBrowserWindowForProfile( | 105 void OpenBrowserWindowForProfile( |
| 106 ProfileManager::CreateCallback callback, | 106 ProfileManager::CreateCallback callback, |
| 107 bool always_create, | 107 bool always_create, |
| 108 bool is_new_profile, | 108 bool is_new_profile, |
| 109 chrome::HostDesktopType desktop_type, | 109 chrome::HostDesktopType desktop_type, |
| 110 Profile* profile, | 110 Profile* profile, |
| 111 Profile::CreateStatus status) { | 111 Profile::CreateStatus status) { |
| 112 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); | 112 DCHECK_CURRENTLY_ON(BrowserThread::UI); |
| 113 | 113 |
| 114 if (status != Profile::CREATE_STATUS_INITIALIZED) | 114 if (status != Profile::CREATE_STATUS_INITIALIZED) |
| 115 return; | 115 return; |
| 116 | 116 |
| 117 chrome::startup::IsProcessStartup is_process_startup = | 117 chrome::startup::IsProcessStartup is_process_startup = |
| 118 chrome::startup::IS_NOT_PROCESS_STARTUP; | 118 chrome::startup::IS_NOT_PROCESS_STARTUP; |
| 119 chrome::startup::IsFirstRun is_first_run = chrome::startup::IS_NOT_FIRST_RUN; | 119 chrome::startup::IsFirstRun is_first_run = chrome::startup::IS_NOT_FIRST_RUN; |
| 120 | 120 |
| 121 // If this is a brand new profile, then start a first run window. | 121 // If this is a brand new profile, then start a first run window. |
| 122 if (is_new_profile) { | 122 if (is_new_profile) { |
| (...skipping 394 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 517 return; | 517 return; |
| 518 case BrowserWindow::AVATAR_BUBBLE_MODE_FAST_USER_SWITCH: | 518 case BrowserWindow::AVATAR_BUBBLE_MODE_FAST_USER_SWITCH: |
| 519 *bubble_view_mode = profiles::BUBBLE_VIEW_MODE_FAST_PROFILE_CHOOSER; | 519 *bubble_view_mode = profiles::BUBBLE_VIEW_MODE_FAST_PROFILE_CHOOSER; |
| 520 return; | 520 return; |
| 521 default: | 521 default: |
| 522 *bubble_view_mode = profiles::BUBBLE_VIEW_MODE_PROFILE_CHOOSER; | 522 *bubble_view_mode = profiles::BUBBLE_VIEW_MODE_PROFILE_CHOOSER; |
| 523 } | 523 } |
| 524 } | 524 } |
| 525 | 525 |
| 526 } // namespace profiles | 526 } // namespace profiles |
| OLD | NEW |