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_LOCK_WEBUI_SCREEN_LOCKER_H_ | 5 #ifndef CHROME_BROWSER_CHROMEOS_LOGIN_LOCK_WEBUI_SCREEN_LOCKER_H_ |
6 #define CHROME_BROWSER_CHROMEOS_LOGIN_LOCK_WEBUI_SCREEN_LOCKER_H_ | 6 #define CHROME_BROWSER_CHROMEOS_LOGIN_LOCK_WEBUI_SCREEN_LOCKER_H_ |
7 | 7 |
8 #include <stdint.h> | 8 #include <stdint.h> |
9 | 9 |
| 10 #include <memory> |
10 #include <string> | 11 #include <string> |
11 | 12 |
12 #include "ash/shell_delegate.h" | 13 #include "ash/shell_delegate.h" |
13 #include "ash/wm/lock_state_observer.h" | 14 #include "ash/wm/lock_state_observer.h" |
14 #include "base/compiler_specific.h" | 15 #include "base/compiler_specific.h" |
15 #include "base/macros.h" | 16 #include "base/macros.h" |
16 #include "base/memory/scoped_ptr.h" | |
17 #include "base/memory/weak_ptr.h" | 17 #include "base/memory/weak_ptr.h" |
18 #include "base/time/time.h" | 18 #include "base/time/time.h" |
19 #include "chrome/browser/chromeos/login/lock/screen_locker_delegate.h" | 19 #include "chrome/browser/chromeos/login/lock/screen_locker_delegate.h" |
20 #include "chrome/browser/chromeos/login/signin_screen_controller.h" | 20 #include "chrome/browser/chromeos/login/signin_screen_controller.h" |
21 #include "chrome/browser/chromeos/login/signin_specifics.h" | 21 #include "chrome/browser/chromeos/login/signin_specifics.h" |
22 #include "chrome/browser/chromeos/login/ui/lock_window.h" | 22 #include "chrome/browser/chromeos/login/ui/lock_window.h" |
23 #include "chrome/browser/chromeos/login/ui/login_display.h" | 23 #include "chrome/browser/chromeos/login/ui/login_display.h" |
24 #include "chrome/browser/chromeos/login/ui/webui_login_view.h" | 24 #include "chrome/browser/chromeos/login/ui/webui_login_view.h" |
25 #include "chromeos/dbus/power_manager_client.h" | 25 #include "chromeos/dbus/power_manager_client.h" |
26 #include "content/public/browser/web_contents_observer.h" | 26 #include "content/public/browser/web_contents_observer.h" |
(...skipping 119 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
146 // Ensures that user pod is focused. | 146 // Ensures that user pod is focused. |
147 void FocusUserPod(); | 147 void FocusUserPod(); |
148 | 148 |
149 // Reset user pod and ensures that user pod is focused. | 149 // Reset user pod and ensures that user pod is focused. |
150 void ResetAndFocusUserPod(); | 150 void ResetAndFocusUserPod(); |
151 | 151 |
152 // The screen locker window. | 152 // The screen locker window. |
153 views::Widget* lock_window_; | 153 views::Widget* lock_window_; |
154 | 154 |
155 // Sign-in Screen controller instance (owns login screens). | 155 // Sign-in Screen controller instance (owns login screens). |
156 scoped_ptr<SignInScreenController> signin_screen_controller_; | 156 std::unique_ptr<SignInScreenController> signin_screen_controller_; |
157 | 157 |
158 // Login UI implementation instance. | 158 // Login UI implementation instance. |
159 scoped_ptr<WebUILoginDisplay> login_display_; | 159 std::unique_ptr<WebUILoginDisplay> login_display_; |
160 | 160 |
161 // Tracks when the lock window is displayed and ready. | 161 // Tracks when the lock window is displayed and ready. |
162 bool lock_ready_; | 162 bool lock_ready_; |
163 | 163 |
164 // Tracks when the WebUI finishes loading. | 164 // Tracks when the WebUI finishes loading. |
165 bool webui_ready_; | 165 bool webui_ready_; |
166 | 166 |
167 // Time when lock was initiated, required for metrics. | 167 // Time when lock was initiated, required for metrics. |
168 base::TimeTicks lock_time_; | 168 base::TimeTicks lock_time_; |
169 | 169 |
170 scoped_ptr<login::NetworkStateHelper> network_state_helper_; | 170 std::unique_ptr<login::NetworkStateHelper> network_state_helper_; |
171 | 171 |
172 // True is subscribed as keyboard controller observer. | 172 // True is subscribed as keyboard controller observer. |
173 bool is_observing_keyboard_; | 173 bool is_observing_keyboard_; |
174 | 174 |
175 base::WeakPtrFactory<WebUIScreenLocker> weak_factory_; | 175 base::WeakPtrFactory<WebUIScreenLocker> weak_factory_; |
176 | 176 |
177 DISALLOW_COPY_AND_ASSIGN(WebUIScreenLocker); | 177 DISALLOW_COPY_AND_ASSIGN(WebUIScreenLocker); |
178 }; | 178 }; |
179 | 179 |
180 } // namespace chromeos | 180 } // namespace chromeos |
181 | 181 |
182 #endif // CHROME_BROWSER_CHROMEOS_LOGIN_LOCK_WEBUI_SCREEN_LOCKER_H_ | 182 #endif // CHROME_BROWSER_CHROMEOS_LOGIN_LOCK_WEBUI_SCREEN_LOCKER_H_ |
OLD | NEW |