| 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_WIZARD_CONTROLLER_H_ | 5 #ifndef CHROME_BROWSER_CHROMEOS_LOGIN_WIZARD_CONTROLLER_H_ |
| 6 #define CHROME_BROWSER_CHROMEOS_LOGIN_WIZARD_CONTROLLER_H_ | 6 #define CHROME_BROWSER_CHROMEOS_LOGIN_WIZARD_CONTROLLER_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/compiler_specific.h" | 10 #include "base/compiler_specific.h" |
| (...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 76 // Sets delays to zero. MUST be used only for tests. | 76 // Sets delays to zero. MUST be used only for tests. |
| 77 static void SetZeroDelays(); | 77 static void SetZeroDelays(); |
| 78 | 78 |
| 79 // If true zero delays have been enabled (for browser tests). | 79 // If true zero delays have been enabled (for browser tests). |
| 80 static bool IsZeroDelayEnabled(); | 80 static bool IsZeroDelayEnabled(); |
| 81 | 81 |
| 82 // Skips any screens that may normally be shown after login (registration, | 82 // Skips any screens that may normally be shown after login (registration, |
| 83 // Terms of Service, user image selection). | 83 // Terms of Service, user image selection). |
| 84 static void SkipPostLoginScreensForTesting(); | 84 static void SkipPostLoginScreensForTesting(); |
| 85 | 85 |
| 86 // Checks whether OOBE should start enrollment automatically. |
| 87 static bool ShouldAutoStartEnrollment(); |
| 88 |
| 86 // Shows the first screen defined by |first_screen_name| or by default | 89 // Shows the first screen defined by |first_screen_name| or by default |
| 87 // if the parameter is empty. Takes ownership of |screen_parameters|. | 90 // if the parameter is empty. Takes ownership of |screen_parameters|. |
| 88 void Init(const std::string& first_screen_name, | 91 void Init(const std::string& first_screen_name, |
| 89 scoped_ptr<base::DictionaryValue> screen_parameters); | 92 scoped_ptr<base::DictionaryValue> screen_parameters); |
| 90 | 93 |
| 91 // Advances to screen defined by |screen_name| and shows it. | 94 // Advances to screen defined by |screen_name| and shows it. |
| 92 void AdvanceToScreen(const std::string& screen_name); | 95 void AdvanceToScreen(const std::string& screen_name); |
| 93 | 96 |
| 94 // Advances to screen defined by |screen_name| and shows it. | 97 // Advances to screen defined by |screen_name| and shows it. |
| 95 // Takes ownership of |screen_parameters|. | 98 // Takes ownership of |screen_parameters|. |
| (...skipping 131 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 227 | 230 |
| 228 // Changes status area visibility. | 231 // Changes status area visibility. |
| 229 void SetStatusAreaVisible(bool visible); | 232 void SetStatusAreaVisible(bool visible); |
| 230 | 233 |
| 231 // Logs in the specified user via default login screen. | 234 // Logs in the specified user via default login screen. |
| 232 void Login(const std::string& username, const std::string& password); | 235 void Login(const std::string& username, const std::string& password); |
| 233 | 236 |
| 234 // Launched kiosk app configured for auto-launch. | 237 // Launched kiosk app configured for auto-launch. |
| 235 void AutoLaunchKioskApp(); | 238 void AutoLaunchKioskApp(); |
| 236 | 239 |
| 237 // Checks whether OOBE should start enrollment automatically. | |
| 238 bool ShouldAutoStartEnrollment() const; | |
| 239 | |
| 240 // Checks whether the user is allowed to exit enrollment. | 240 // Checks whether the user is allowed to exit enrollment. |
| 241 bool CanExitEnrollment() const; | 241 bool CanExitEnrollment() const; |
| 242 | 242 |
| 243 // Called when LocalState is initialized. | 243 // Called when LocalState is initialized. |
| 244 void OnLocalStateInitialized(bool /* succeeded */); | 244 void OnLocalStateInitialized(bool /* succeeded */); |
| 245 | 245 |
| 246 // Returns local state. | 246 // Returns local state. |
| 247 PrefService* GetLocalState(); | 247 PrefService* GetLocalState(); |
| 248 | 248 |
| 249 static void set_local_state_for_testing(PrefService* local_state) { | 249 static void set_local_state_for_testing(PrefService* local_state) { |
| (...skipping 82 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 332 friend class WizardControllerBrokenLocalStateTest; | 332 friend class WizardControllerBrokenLocalStateTest; |
| 333 | 333 |
| 334 base::WeakPtrFactory<WizardController> weak_factory_; | 334 base::WeakPtrFactory<WizardController> weak_factory_; |
| 335 | 335 |
| 336 DISALLOW_COPY_AND_ASSIGN(WizardController); | 336 DISALLOW_COPY_AND_ASSIGN(WizardController); |
| 337 }; | 337 }; |
| 338 | 338 |
| 339 } // namespace chromeos | 339 } // namespace chromeos |
| 340 | 340 |
| 341 #endif // CHROME_BROWSER_CHROMEOS_LOGIN_WIZARD_CONTROLLER_H_ | 341 #endif // CHROME_BROWSER_CHROMEOS_LOGIN_WIZARD_CONTROLLER_H_ |
| OLD | NEW |