| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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/session/chrome_session_manager.h" | 5 #include "chrome/browser/chromeos/login/session/chrome_session_manager.h" |
| 6 | 6 |
| 7 #include <memory> | 7 #include <memory> |
| 8 | 8 |
| 9 #include "base/command_line.h" | 9 #include "base/command_line.h" |
| 10 #include "base/logging.h" | 10 #include "base/logging.h" |
| 11 #include "base/sys_info.h" | 11 #include "base/sys_info.h" |
| 12 #include "chrome/browser/browser_process.h" | 12 #include "chrome/browser/browser_process.h" |
| 13 #include "chrome/browser/browser_process_platform_part_chromeos.h" | 13 #include "chrome/browser/browser_process_platform_part_chromeos.h" |
| 14 #include "chrome/browser/chrome_notification_types.h" | 14 #include "chrome/browser/chrome_notification_types.h" |
| 15 #include "chrome/browser/chromeos/app_mode/kiosk_app_launch_error.h" | 15 #include "chrome/browser/chromeos/app_mode/kiosk_app_launch_error.h" |
| 16 #include "chrome/browser/chromeos/app_mode/kiosk_app_manager.h" | 16 #include "chrome/browser/chromeos/app_mode/kiosk_app_manager.h" |
| 17 #include "chrome/browser/chromeos/arc/arc_auth_service.h" | 17 #include "chrome/browser/chromeos/arc/arc_auth_service.h" |
| 18 #include "chrome/browser/chromeos/boot_times_recorder.h" |
| 18 #include "chrome/browser/chromeos/login/login_wizard.h" | 19 #include "chrome/browser/chromeos/login/login_wizard.h" |
| 19 #include "chrome/browser/chromeos/login/session/user_session_manager.h" | 20 #include "chrome/browser/chromeos/login/session/user_session_manager.h" |
| 20 #include "chrome/browser/chromeos/login/wizard_controller.h" | 21 #include "chrome/browser/chromeos/login/wizard_controller.h" |
| 21 #include "chrome/browser/chromeos/policy/browser_policy_connector_chromeos.h" | 22 #include "chrome/browser/chromeos/policy/browser_policy_connector_chromeos.h" |
| 22 #include "chrome/browser/profiles/profile.h" | 23 #include "chrome/browser/profiles/profile.h" |
| 23 #include "chrome/browser/signin/signin_manager_factory.h" | 24 #include "chrome/browser/signin/signin_manager_factory.h" |
| 24 #include "chrome/browser/ui/ash/ash_util.h" | 25 #include "chrome/browser/ui/ash/ash_util.h" |
| 25 #include "chrome/browser/ui/ash/multi_user/multi_user_util.h" | 26 #include "chrome/browser/ui/ash/multi_user/multi_user_util.h" |
| 26 #include "chrome/common/chrome_switches.h" | 27 #include "chrome/common/chrome_switches.h" |
| 27 #include "chrome/common/pref_names.h" | 28 #include "chrome/common/pref_names.h" |
| (...skipping 205 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 233 if (user_manager) | 234 if (user_manager) |
| 234 user_manager->OnSessionStarted(); | 235 user_manager->OnSessionStarted(); |
| 235 | 236 |
| 236 content::NotificationService::current()->Notify( | 237 content::NotificationService::current()->Notify( |
| 237 chrome::NOTIFICATION_SESSION_STARTED, | 238 chrome::NOTIFICATION_SESSION_STARTED, |
| 238 content::Source<session_manager::SessionManager>(this), | 239 content::Source<session_manager::SessionManager>(this), |
| 239 content::Details<const user_manager::User>( | 240 content::Details<const user_manager::User>( |
| 240 user_manager->GetActiveUser())); | 241 user_manager->GetActiveUser())); |
| 241 } | 242 } |
| 242 | 243 |
| 244 void ChromeSessionManager::NotifyUserLoggedIn(const AccountId& user_account_id, |
| 245 const std::string& user_id_hash, |
| 246 bool browser_restart) { |
| 247 BootTimesRecorder* btl = BootTimesRecorder::Get(); |
| 248 btl->AddLoginTimeMarker("UserLoggedIn-Start", false); |
| 249 session_manager::SessionManager::NotifyUserLoggedIn( |
| 250 user_account_id, user_id_hash, browser_restart); |
| 251 btl->AddLoginTimeMarker("UserLoggedIn-End", false); |
| 252 } |
| 253 |
| 243 } // namespace chromeos | 254 } // namespace chromeos |
| OLD | NEW |