| OLD | NEW |
| 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/chromeos/login/existing_user_controller.h" | 5 #include "chrome/browser/chromeos/login/existing_user_controller.h" |
| 6 | 6 |
| 7 #include <vector> | 7 #include <vector> |
| 8 | 8 |
| 9 #include "base/bind.h" | 9 #include "base/bind.h" |
| 10 #include "base/bind_helpers.h" | 10 #include "base/bind_helpers.h" |
| 11 #include "base/callback.h" | 11 #include "base/callback.h" |
| 12 #include "base/command_line.h" | 12 #include "base/command_line.h" |
| 13 #include "base/logging.h" | 13 #include "base/logging.h" |
| 14 #include "base/memory/scoped_ptr.h" | 14 #include "base/memory/scoped_ptr.h" |
| 15 #include "base/message_loop/message_loop.h" | 15 #include "base/message_loop/message_loop.h" |
| 16 #include "base/metrics/histogram.h" | 16 #include "base/metrics/histogram.h" |
| 17 #include "base/prefs/pref_service.h" | |
| 18 #include "base/strings/string_util.h" | 17 #include "base/strings/string_util.h" |
| 19 #include "base/strings/utf_string_conversions.h" | 18 #include "base/strings/utf_string_conversions.h" |
| 20 #include "base/values.h" | 19 #include "base/values.h" |
| 21 #include "base/version.h" | 20 #include "base/version.h" |
| 22 #include "chrome/browser/browser_process.h" | 21 #include "chrome/browser/browser_process.h" |
| 23 #include "chrome/browser/browser_process_platform_part.h" | 22 #include "chrome/browser/browser_process_platform_part.h" |
| 24 #include "chrome/browser/chrome_notification_types.h" | 23 #include "chrome/browser/chrome_notification_types.h" |
| 25 #include "chrome/browser/chromeos/boot_times_recorder.h" | 24 #include "chrome/browser/chromeos/boot_times_recorder.h" |
| 26 #include "chrome/browser/chromeos/customization/customization_document.h" | 25 #include "chrome/browser/chromeos/customization/customization_document.h" |
| 27 #include "chrome/browser/chromeos/login/auth/chrome_login_performer.h" | 26 #include "chrome/browser/chromeos/login/auth/chrome_login_performer.h" |
| (...skipping 26 matching lines...) Expand all Loading... |
| 54 #include "chromeos/dbus/power_manager_client.h" | 53 #include "chromeos/dbus/power_manager_client.h" |
| 55 #include "chromeos/dbus/session_manager_client.h" | 54 #include "chromeos/dbus/session_manager_client.h" |
| 56 #include "chromeos/login/user_names.h" | 55 #include "chromeos/login/user_names.h" |
| 57 #include "chromeos/settings/cros_settings_names.h" | 56 #include "chromeos/settings/cros_settings_names.h" |
| 58 #include "components/google/core/browser/google_util.h" | 57 #include "components/google/core/browser/google_util.h" |
| 59 #include "components/policy/core/common/cloud/cloud_policy_core.h" | 58 #include "components/policy/core/common/cloud/cloud_policy_core.h" |
| 60 #include "components/policy/core/common/cloud/cloud_policy_store.h" | 59 #include "components/policy/core/common/cloud/cloud_policy_store.h" |
| 61 #include "components/policy/core/common/policy_map.h" | 60 #include "components/policy/core/common/policy_map.h" |
| 62 #include "components/policy/core/common/policy_service.h" | 61 #include "components/policy/core/common/policy_service.h" |
| 63 #include "components/policy/core/common/policy_types.h" | 62 #include "components/policy/core/common/policy_types.h" |
| 63 #include "components/prefs/pref_service.h" |
| 64 #include "components/signin/core/account_id/account_id.h" | 64 #include "components/signin/core/account_id/account_id.h" |
| 65 #include "components/signin/core/browser/signin_client.h" | 65 #include "components/signin/core/browser/signin_client.h" |
| 66 #include "components/user_manager/known_user.h" | 66 #include "components/user_manager/known_user.h" |
| 67 #include "components/user_manager/user_manager.h" | 67 #include "components/user_manager/user_manager.h" |
| 68 #include "components/user_manager/user_type.h" | 68 #include "components/user_manager/user_type.h" |
| 69 #include "content/public/browser/browser_thread.h" | 69 #include "content/public/browser/browser_thread.h" |
| 70 #include "content/public/browser/notification_service.h" | 70 #include "content/public/browser/notification_service.h" |
| 71 #include "content/public/browser/notification_types.h" | 71 #include "content/public/browser/notification_types.h" |
| 72 #include "content/public/browser/user_metrics.h" | 72 #include "content/public/browser/user_metrics.h" |
| 73 #include "google_apis/gaia/gaia_auth_util.h" | 73 #include "google_apis/gaia/gaia_auth_util.h" |
| (...skipping 1127 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1201 if (!success) { | 1201 if (!success) { |
| 1202 LOG(ERROR) << "OAuth2 token fetch failed."; | 1202 LOG(ERROR) << "OAuth2 token fetch failed."; |
| 1203 OnAuthFailure(AuthFailure(AuthFailure::FAILED_TO_INITIALIZE_TOKEN)); | 1203 OnAuthFailure(AuthFailure(AuthFailure::FAILED_TO_INITIALIZE_TOKEN)); |
| 1204 return; | 1204 return; |
| 1205 } | 1205 } |
| 1206 UserSessionManager::GetInstance()->OnOAuth2TokensFetched(user_context); | 1206 UserSessionManager::GetInstance()->OnOAuth2TokensFetched(user_context); |
| 1207 PerformLogin(user_context, LoginPerformer::AUTH_MODE_EXTENSION); | 1207 PerformLogin(user_context, LoginPerformer::AUTH_MODE_EXTENSION); |
| 1208 } | 1208 } |
| 1209 | 1209 |
| 1210 } // namespace chromeos | 1210 } // namespace chromeos |
| OLD | NEW |