| OLD | NEW |
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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/chromeos/login/login_utils.h" | 5 #include "chrome/browser/chromeos/login/login_utils.h" |
| 6 | 6 |
| 7 #include <vector> | 7 #include <vector> |
| 8 | 8 |
| 9 #include "base/command_line.h" | 9 #include "base/command_line.h" |
| 10 #include "base/file_path.h" | 10 #include "base/file_path.h" |
| (...skipping 13 matching lines...) Expand all Loading... |
| 24 #include "chrome/browser/chromeos/cros/network_library.h" | 24 #include "chrome/browser/chromeos/cros/network_library.h" |
| 25 #include "chrome/browser/chromeos/input_method/input_method_util.h" | 25 #include "chrome/browser/chromeos/input_method/input_method_util.h" |
| 26 #include "chrome/browser/chromeos/login/cookie_fetcher.h" | 26 #include "chrome/browser/chromeos/login/cookie_fetcher.h" |
| 27 #include "chrome/browser/chromeos/login/google_authenticator.h" | 27 #include "chrome/browser/chromeos/login/google_authenticator.h" |
| 28 #include "chrome/browser/chromeos/login/language_switch_menu.h" | 28 #include "chrome/browser/chromeos/login/language_switch_menu.h" |
| 29 #include "chrome/browser/chromeos/login/ownership_service.h" | 29 #include "chrome/browser/chromeos/login/ownership_service.h" |
| 30 #include "chrome/browser/chromeos/login/parallel_authenticator.h" | 30 #include "chrome/browser/chromeos/login/parallel_authenticator.h" |
| 31 #include "chrome/browser/chromeos/login/user_image_downloader.h" | 31 #include "chrome/browser/chromeos/login/user_image_downloader.h" |
| 32 #include "chrome/browser/chromeos/login/user_manager.h" | 32 #include "chrome/browser/chromeos/login/user_manager.h" |
| 33 #include "chrome/browser/chromeos/proxy_config_service.h" | 33 #include "chrome/browser/chromeos/proxy_config_service.h" |
| 34 #include "chrome/browser/extensions/extensions_service.h" | 34 #include "chrome/browser/extensions/extension_service.h" |
| 35 #include "chrome/browser/net/chrome_url_request_context.h" | 35 #include "chrome/browser/net/chrome_url_request_context.h" |
| 36 #include "chrome/browser/net/gaia/token_service.h" | 36 #include "chrome/browser/net/gaia/token_service.h" |
| 37 #include "chrome/browser/net/preconnect.h" | 37 #include "chrome/browser/net/preconnect.h" |
| 38 #include "chrome/browser/net/pref_proxy_config_service.h" | 38 #include "chrome/browser/net/pref_proxy_config_service.h" |
| 39 #include "chrome/browser/prefs/pref_member.h" | 39 #include "chrome/browser/prefs/pref_member.h" |
| 40 #include "chrome/browser/profiles/profile.h" | 40 #include "chrome/browser/profiles/profile.h" |
| 41 #include "chrome/browser/profiles/profile_manager.h" | 41 #include "chrome/browser/profiles/profile_manager.h" |
| 42 #include "chrome/browser/sync/profile_sync_service.h" | 42 #include "chrome/browser/sync/profile_sync_service.h" |
| 43 #include "chrome/browser/ui/browser_init.h" | 43 #include "chrome/browser/ui/browser_init.h" |
| 44 #include "chrome/common/chrome_paths.h" | 44 #include "chrome/common/chrome_paths.h" |
| (...skipping 195 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 240 // would perform online auth before calling CompleteLogin. | 240 // would perform online auth before calling CompleteLogin. |
| 241 // For existing users there's usually a pending online auth request. | 241 // For existing users there's usually a pending online auth request. |
| 242 // Cookies will be fetched after it's is succeeded. | 242 // Cookies will be fetched after it's is succeeded. |
| 243 if (!pending_requests) { | 243 if (!pending_requests) { |
| 244 FetchCookies(profile, credentials); | 244 FetchCookies(profile, credentials); |
| 245 } | 245 } |
| 246 | 246 |
| 247 // Init extension event routers; this normally happens in browser_main | 247 // Init extension event routers; this normally happens in browser_main |
| 248 // but on Chrome OS it has to be deferred until the user finishes | 248 // but on Chrome OS it has to be deferred until the user finishes |
| 249 // logging in and the profile is not OTR. | 249 // logging in and the profile is not OTR. |
| 250 if (profile->GetExtensionsService() && | 250 if (profile->GetExtensionService() && |
| 251 profile->GetExtensionsService()->extensions_enabled()) { | 251 profile->GetExtensionService()->extensions_enabled()) { |
| 252 profile->GetExtensionsService()->InitEventRouters(); | 252 profile->GetExtensionService()->InitEventRouters(); |
| 253 } | 253 } |
| 254 btl->AddLoginTimeMarker("ExtensionsServiceStarted", false); | 254 btl->AddLoginTimeMarker("ExtensionsServiceStarted", false); |
| 255 | 255 |
| 256 // Supply credentials for sync and others to use. Load tokens from disk. | 256 // Supply credentials for sync and others to use. Load tokens from disk. |
| 257 TokenService* token_service = profile->GetTokenService(); | 257 TokenService* token_service = profile->GetTokenService(); |
| 258 token_service->Initialize(GaiaConstants::kChromeOSSource, | 258 token_service->Initialize(GaiaConstants::kChromeOSSource, |
| 259 profile); | 259 profile); |
| 260 token_service->LoadTokensFromDB(); | 260 token_service->LoadTokensFromDB(); |
| 261 | 261 |
| 262 // For existing users there's usually a pending online auth request. | 262 // For existing users there's usually a pending online auth request. |
| (...skipping 254 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 517 BrowserInit browser_init; | 517 BrowserInit browser_init; |
| 518 int return_code; | 518 int return_code; |
| 519 browser_init.LaunchBrowser(*CommandLine::ForCurrentProcess(), | 519 browser_init.LaunchBrowser(*CommandLine::ForCurrentProcess(), |
| 520 profile, | 520 profile, |
| 521 FilePath(), | 521 FilePath(), |
| 522 true, | 522 true, |
| 523 &return_code); | 523 &return_code); |
| 524 } | 524 } |
| 525 | 525 |
| 526 } // namespace chromeos | 526 } // namespace chromeos |
| OLD | NEW |