| 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 #ifndef CHROME_BROWSER_CHROMEOS_LOGIN_UI_LOGIN_DISPLAY_HOST_IMPL_H_ | 5 #ifndef CHROME_BROWSER_CHROMEOS_LOGIN_UI_LOGIN_DISPLAY_HOST_IMPL_H_ |
| 6 #define CHROME_BROWSER_CHROMEOS_LOGIN_UI_LOGIN_DISPLAY_HOST_IMPL_H_ | 6 #define CHROME_BROWSER_CHROMEOS_LOGIN_UI_LOGIN_DISPLAY_HOST_IMPL_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| (...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 60 explicit LoginDisplayHostImpl(const gfx::Rect& background_bounds); | 60 explicit LoginDisplayHostImpl(const gfx::Rect& background_bounds); |
| 61 virtual ~LoginDisplayHostImpl(); | 61 virtual ~LoginDisplayHostImpl(); |
| 62 | 62 |
| 63 // Returns the default LoginDisplayHost instance if it has been created. | 63 // Returns the default LoginDisplayHost instance if it has been created. |
| 64 static LoginDisplayHost* default_host() { | 64 static LoginDisplayHost* default_host() { |
| 65 return default_host_; | 65 return default_host_; |
| 66 } | 66 } |
| 67 | 67 |
| 68 // LoginDisplayHost implementation: | 68 // LoginDisplayHost implementation: |
| 69 virtual LoginDisplay* CreateLoginDisplay( | 69 virtual LoginDisplay* CreateLoginDisplay( |
| 70 LoginDisplay::Delegate* delegate) OVERRIDE; | 70 LoginDisplay::Delegate* delegate) override; |
| 71 virtual gfx::NativeWindow GetNativeWindow() const OVERRIDE; | 71 virtual gfx::NativeWindow GetNativeWindow() const override; |
| 72 virtual WebUILoginView* GetWebUILoginView() const OVERRIDE; | 72 virtual WebUILoginView* GetWebUILoginView() const override; |
| 73 virtual void BeforeSessionStart() OVERRIDE; | 73 virtual void BeforeSessionStart() override; |
| 74 virtual void Finalize() OVERRIDE; | 74 virtual void Finalize() override; |
| 75 virtual void OnCompleteLogin() OVERRIDE; | 75 virtual void OnCompleteLogin() override; |
| 76 virtual void OpenProxySettings() OVERRIDE; | 76 virtual void OpenProxySettings() override; |
| 77 virtual void SetStatusAreaVisible(bool visible) OVERRIDE; | 77 virtual void SetStatusAreaVisible(bool visible) override; |
| 78 virtual AutoEnrollmentController* GetAutoEnrollmentController() OVERRIDE; | 78 virtual AutoEnrollmentController* GetAutoEnrollmentController() override; |
| 79 virtual void StartWizard( | 79 virtual void StartWizard( |
| 80 const std::string& first_screen_name, | 80 const std::string& first_screen_name, |
| 81 scoped_ptr<base::DictionaryValue> screen_parameters) OVERRIDE; | 81 scoped_ptr<base::DictionaryValue> screen_parameters) override; |
| 82 virtual WizardController* GetWizardController() OVERRIDE; | 82 virtual WizardController* GetWizardController() override; |
| 83 virtual AppLaunchController* GetAppLaunchController() OVERRIDE; | 83 virtual AppLaunchController* GetAppLaunchController() override; |
| 84 virtual void StartUserAdding( | 84 virtual void StartUserAdding( |
| 85 const base::Closure& completion_callback) OVERRIDE; | 85 const base::Closure& completion_callback) override; |
| 86 virtual void StartSignInScreen(const LoginScreenContext& context) OVERRIDE; | 86 virtual void StartSignInScreen(const LoginScreenContext& context) override; |
| 87 virtual void ResumeSignInScreen() OVERRIDE; | 87 virtual void ResumeSignInScreen() override; |
| 88 virtual void OnPreferencesChanged() OVERRIDE; | 88 virtual void OnPreferencesChanged() override; |
| 89 virtual void PrewarmAuthentication() OVERRIDE; | 89 virtual void PrewarmAuthentication() override; |
| 90 virtual void StartAppLaunch(const std::string& app_id, | 90 virtual void StartAppLaunch(const std::string& app_id, |
| 91 bool diagnostic_mode) OVERRIDE; | 91 bool diagnostic_mode) override; |
| 92 virtual void StartDemoAppLaunch() OVERRIDE; | 92 virtual void StartDemoAppLaunch() override; |
| 93 | 93 |
| 94 // Creates WizardController instance. | 94 // Creates WizardController instance. |
| 95 WizardController* CreateWizardController(); | 95 WizardController* CreateWizardController(); |
| 96 | 96 |
| 97 // Called when the first browser window is created, but before it's shown. | 97 // Called when the first browser window is created, but before it's shown. |
| 98 void OnBrowserCreated(); | 98 void OnBrowserCreated(); |
| 99 | 99 |
| 100 // Returns instance of the OOBE WebUI. | 100 // Returns instance of the OOBE WebUI. |
| 101 OobeUI* GetOobeUI() const; | 101 OobeUI* GetOobeUI() const; |
| 102 | 102 |
| 103 const gfx::Rect& background_bounds() const { return background_bounds_; } | 103 const gfx::Rect& background_bounds() const { return background_bounds_; } |
| 104 | 104 |
| 105 // Trace id for ShowLoginWebUI event (since there exists at most one login | 105 // Trace id for ShowLoginWebUI event (since there exists at most one login |
| 106 // WebUI at a time). | 106 // WebUI at a time). |
| 107 static const int kShowLoginWebUIid; | 107 static const int kShowLoginWebUIid; |
| 108 | 108 |
| 109 views::Widget* login_window_for_test() { return login_window_; } | 109 views::Widget* login_window_for_test() { return login_window_; } |
| 110 | 110 |
| 111 protected: | 111 protected: |
| 112 // content::NotificationObserver implementation: | 112 // content::NotificationObserver implementation: |
| 113 virtual void Observe(int type, | 113 virtual void Observe(int type, |
| 114 const content::NotificationSource& source, | 114 const content::NotificationSource& source, |
| 115 const content::NotificationDetails& details) OVERRIDE; | 115 const content::NotificationDetails& details) override; |
| 116 | 116 |
| 117 // Overridden from content::WebContentsObserver: | 117 // Overridden from content::WebContentsObserver: |
| 118 virtual void RenderProcessGone(base::TerminationStatus status) OVERRIDE; | 118 virtual void RenderProcessGone(base::TerminationStatus status) override; |
| 119 | 119 |
| 120 // Overridden from chromeos::SessionManagerClient::Observer: | 120 // Overridden from chromeos::SessionManagerClient::Observer: |
| 121 virtual void EmitLoginPromptVisibleCalled() OVERRIDE; | 121 virtual void EmitLoginPromptVisibleCalled() override; |
| 122 | 122 |
| 123 // Overridden from chromeos::CrasAudioHandler::AudioObserver: | 123 // Overridden from chromeos::CrasAudioHandler::AudioObserver: |
| 124 virtual void OnActiveOutputNodeChanged() OVERRIDE; | 124 virtual void OnActiveOutputNodeChanged() override; |
| 125 | 125 |
| 126 // Overridden from ash::KeyboardStateObserver: | 126 // Overridden from ash::KeyboardStateObserver: |
| 127 virtual void OnVirtualKeyboardStateChanged(bool activated) OVERRIDE; | 127 virtual void OnVirtualKeyboardStateChanged(bool activated) override; |
| 128 | 128 |
| 129 // Overridden from keyboard::KeyboardControllerObserver: | 129 // Overridden from keyboard::KeyboardControllerObserver: |
| 130 virtual void OnKeyboardBoundsChanging(const gfx::Rect& new_bounds) OVERRIDE; | 130 virtual void OnKeyboardBoundsChanging(const gfx::Rect& new_bounds) override; |
| 131 | 131 |
| 132 // Overridden from gfx::DisplayObserver: | 132 // Overridden from gfx::DisplayObserver: |
| 133 virtual void OnDisplayAdded(const gfx::Display& new_display) OVERRIDE; | 133 virtual void OnDisplayAdded(const gfx::Display& new_display) override; |
| 134 virtual void OnDisplayRemoved(const gfx::Display& old_display) OVERRIDE; | 134 virtual void OnDisplayRemoved(const gfx::Display& old_display) override; |
| 135 virtual void OnDisplayMetricsChanged(const gfx::Display& display, | 135 virtual void OnDisplayMetricsChanged(const gfx::Display& display, |
| 136 uint32_t changed_metrics) OVERRIDE; | 136 uint32_t changed_metrics) override; |
| 137 | 137 |
| 138 // Overriden from views::WidgetRemovalsObserver: | 138 // Overriden from views::WidgetRemovalsObserver: |
| 139 virtual void OnWillRemoveView(views::Widget* widget, | 139 virtual void OnWillRemoveView(views::Widget* widget, |
| 140 views::View* view) OVERRIDE; | 140 views::View* view) override; |
| 141 | 141 |
| 142 private: | 142 private: |
| 143 // Way to restore if renderer have crashed. | 143 // Way to restore if renderer have crashed. |
| 144 enum RestorePath { | 144 enum RestorePath { |
| 145 RESTORE_UNKNOWN, | 145 RESTORE_UNKNOWN, |
| 146 RESTORE_WIZARD, | 146 RESTORE_WIZARD, |
| 147 RESTORE_SIGN_IN, | 147 RESTORE_SIGN_IN, |
| 148 RESTORE_ADD_USER_INTO_SESSION, | 148 RESTORE_ADD_USER_INTO_SESSION, |
| 149 }; | 149 }; |
| 150 | 150 |
| (...skipping 171 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 322 #endif | 322 #endif |
| 323 | 323 |
| 324 base::WeakPtrFactory<LoginDisplayHostImpl> animation_weak_ptr_factory_; | 324 base::WeakPtrFactory<LoginDisplayHostImpl> animation_weak_ptr_factory_; |
| 325 | 325 |
| 326 DISALLOW_COPY_AND_ASSIGN(LoginDisplayHostImpl); | 326 DISALLOW_COPY_AND_ASSIGN(LoginDisplayHostImpl); |
| 327 }; | 327 }; |
| 328 | 328 |
| 329 } // namespace chromeos | 329 } // namespace chromeos |
| 330 | 330 |
| 331 #endif // CHROME_BROWSER_CHROMEOS_LOGIN_UI_LOGIN_DISPLAY_HOST_IMPL_H_ | 331 #endif // CHROME_BROWSER_CHROMEOS_LOGIN_UI_LOGIN_DISPLAY_HOST_IMPL_H_ |
| OLD | NEW |