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/user_session_manager.h" | 5 #include "chrome/browser/chromeos/login/session/user_session_manager.h" |
6 | 6 |
7 #include <string> | 7 #include <string> |
8 | 8 |
9 #include "base/base_paths.h" | 9 #include "base/base_paths.h" |
10 #include "base/bind.h" | 10 #include "base/bind.h" |
(...skipping 962 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
973 // UserSessionManager::PrepareProfile() has set |delegate_| when Chrome is | 973 // UserSessionManager::PrepareProfile() has set |delegate_| when Chrome is |
974 // killed during shutdown in tests -- see http://crosbug.com/18269. Replace | 974 // killed during shutdown in tests -- see http://crosbug.com/18269. Replace |
975 // this 'if' statement with a CHECK(delegate_) once the underlying issue is | 975 // this 'if' statement with a CHECK(delegate_) once the underlying issue is |
976 // resolved. | 976 // resolved. |
977 if (delegate_) | 977 if (delegate_) |
978 delegate_->OnProfilePrepared(profile, browser_launched); | 978 delegate_->OnProfilePrepared(profile, browser_launched); |
979 } | 979 } |
980 | 980 |
981 void UserSessionManager::ActivateWizard(const std::string& screen_name) { | 981 void UserSessionManager::ActivateWizard(const std::string& screen_name) { |
982 LoginDisplayHost* host = LoginDisplayHostImpl::default_host(); | 982 LoginDisplayHost* host = LoginDisplayHostImpl::default_host(); |
983 DCHECK(host); | 983 CHECK(host); |
984 if (host) { | 984 scoped_ptr<base::DictionaryValue> params; |
985 scoped_ptr<base::DictionaryValue> params; | 985 host->StartWizard(screen_name, params.Pass()); |
986 host->StartWizard(screen_name, params.Pass()); | |
987 } | |
988 } | 986 } |
989 | 987 |
990 void UserSessionManager::InitializeStartUrls() const { | 988 void UserSessionManager::InitializeStartUrls() const { |
991 std::vector<std::string> start_urls; | 989 std::vector<std::string> start_urls; |
992 | 990 |
993 const base::ListValue *urls; | 991 const base::ListValue *urls; |
994 user_manager::UserManager* user_manager = user_manager::UserManager::Get(); | 992 user_manager::UserManager* user_manager = user_manager::UserManager::Get(); |
995 bool can_show_getstarted_guide = | 993 bool can_show_getstarted_guide = |
996 user_manager->GetActiveUser()->GetType() == | 994 user_manager->GetActiveUser()->GetType() == |
997 user_manager::USER_TYPE_REGULAR && | 995 user_manager::USER_TYPE_REGULAR && |
(...skipping 393 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1391 } | 1389 } |
1392 | 1390 |
1393 EasyUnlockKeyManager* UserSessionManager::GetEasyUnlockKeyManager() { | 1391 EasyUnlockKeyManager* UserSessionManager::GetEasyUnlockKeyManager() { |
1394 if (!easy_unlock_key_manager_) | 1392 if (!easy_unlock_key_manager_) |
1395 easy_unlock_key_manager_.reset(new EasyUnlockKeyManager); | 1393 easy_unlock_key_manager_.reset(new EasyUnlockKeyManager); |
1396 | 1394 |
1397 return easy_unlock_key_manager_.get(); | 1395 return easy_unlock_key_manager_.get(); |
1398 } | 1396 } |
1399 | 1397 |
1400 } // namespace chromeos | 1398 } // namespace chromeos |
OLD | NEW |