| 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 #ifndef CHROME_BROWSER_CHROMEOS_LOGIN_EXISTING_USER_CONTROLLER_H_ | 5 #ifndef CHROME_BROWSER_CHROMEOS_LOGIN_EXISTING_USER_CONTROLLER_H_ |
| 6 #define CHROME_BROWSER_CHROMEOS_LOGIN_EXISTING_USER_CONTROLLER_H_ | 6 #define CHROME_BROWSER_CHROMEOS_LOGIN_EXISTING_USER_CONTROLLER_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
| (...skipping 10 matching lines...) Expand all Loading... |
| 21 #include "chrome/browser/chromeos/login/login_utils.h" | 21 #include "chrome/browser/chromeos/login/login_utils.h" |
| 22 #include "chrome/browser/chromeos/login/ui/login_display.h" | 22 #include "chrome/browser/chromeos/login/ui/login_display.h" |
| 23 #include "chrome/browser/chromeos/settings/cros_settings.h" | 23 #include "chrome/browser/chromeos/settings/cros_settings.h" |
| 24 #include "chrome/browser/chromeos/settings/device_settings_service.h" | 24 #include "chrome/browser/chromeos/settings/device_settings_service.h" |
| 25 #include "components/user_manager/user.h" | 25 #include "components/user_manager/user.h" |
| 26 #include "content/public/browser/notification_observer.h" | 26 #include "content/public/browser/notification_observer.h" |
| 27 #include "content/public/browser/notification_registrar.h" | 27 #include "content/public/browser/notification_registrar.h" |
| 28 #include "ui/gfx/rect.h" | 28 #include "ui/gfx/rect.h" |
| 29 #include "url/gurl.h" | 29 #include "url/gurl.h" |
| 30 | 30 |
| 31 namespace base { |
| 32 class ListValue; |
| 33 } |
| 34 |
| 31 namespace chromeos { | 35 namespace chromeos { |
| 32 | 36 |
| 33 class CrosSettings; | 37 class CrosSettings; |
| 34 class LoginDisplayHost; | 38 class LoginDisplayHost; |
| 35 class UserContext; | 39 class UserContext; |
| 36 | 40 |
| 37 namespace login { | 41 namespace login { |
| 38 class NetworkStateHelper; | 42 class NetworkStateHelper; |
| 39 } | 43 } |
| 40 | 44 |
| (...skipping 172 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 213 // posted as |resume_login_callback_| and resets it. | 217 // posted as |resume_login_callback_| and resets it. |
| 214 void PerformLogin(const UserContext& user_context, | 218 void PerformLogin(const UserContext& user_context, |
| 215 LoginPerformer::AuthorizationMode auth_mode); | 219 LoginPerformer::AuthorizationMode auth_mode); |
| 216 | 220 |
| 217 // Updates the |login_display_| attached to this controller. | 221 // Updates the |login_display_| attached to this controller. |
| 218 void UpdateLoginDisplay(const user_manager::UserList& users); | 222 void UpdateLoginDisplay(const user_manager::UserList& users); |
| 219 | 223 |
| 220 // Sends an accessibility alert event to extension listeners. | 224 // Sends an accessibility alert event to extension listeners. |
| 221 void SendAccessibilityAlert(const std::string& alert_text); | 225 void SendAccessibilityAlert(const std::string& alert_text); |
| 222 | 226 |
| 227 // Callback invoked when the keyboard layouts available for a public session |
| 228 // have been retrieved. Selects the first layout from the list and continues |
| 229 // login. |
| 230 void SetPublicSessionKeyboardLayoutAndLogin( |
| 231 const UserContext& user_context, |
| 232 scoped_ptr<base::ListValue> keyboard_layouts); |
| 233 |
| 234 // Starts the actual login process for a public session. Invoked when all |
| 235 // preconditions have been verified. |
| 236 void LoginAsPublicSessionInternal(const UserContext& user_context); |
| 237 |
| 223 // Public session auto-login timer. | 238 // Public session auto-login timer. |
| 224 scoped_ptr<base::OneShotTimer<ExistingUserController> > auto_login_timer_; | 239 scoped_ptr<base::OneShotTimer<ExistingUserController> > auto_login_timer_; |
| 225 | 240 |
| 226 // Public session auto-login timeout, in milliseconds. | 241 // Public session auto-login timeout, in milliseconds. |
| 227 int public_session_auto_login_delay_; | 242 int public_session_auto_login_delay_; |
| 228 | 243 |
| 229 // Username for public session auto-login. | 244 // Username for public session auto-login. |
| 230 std::string public_session_auto_login_username_; | 245 std::string public_session_auto_login_username_; |
| 231 | 246 |
| 232 // Used to execute login operations. | 247 // Used to execute login operations. |
| (...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 319 local_account_auto_login_delay_subscription_; | 334 local_account_auto_login_delay_subscription_; |
| 320 | 335 |
| 321 FRIEND_TEST_ALL_PREFIXES(ExistingUserControllerTest, ExistingUserLogin); | 336 FRIEND_TEST_ALL_PREFIXES(ExistingUserControllerTest, ExistingUserLogin); |
| 322 | 337 |
| 323 DISALLOW_COPY_AND_ASSIGN(ExistingUserController); | 338 DISALLOW_COPY_AND_ASSIGN(ExistingUserController); |
| 324 }; | 339 }; |
| 325 | 340 |
| 326 } // namespace chromeos | 341 } // namespace chromeos |
| 327 | 342 |
| 328 #endif // CHROME_BROWSER_CHROMEOS_LOGIN_EXISTING_USER_CONTROLLER_H_ | 343 #endif // CHROME_BROWSER_CHROMEOS_LOGIN_EXISTING_USER_CONTROLLER_H_ |
| OLD | NEW |