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 #include "chrome/browser/ui/webui/chromeos/login/oobe_ui.h" | 5 #include "chrome/browser/ui/webui/chromeos/login/oobe_ui.h" |
6 | 6 |
7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
8 #include "base/logging.h" | 8 #include "base/logging.h" |
9 #include "base/memory/scoped_ptr.h" | 9 #include "base/memory/scoped_ptr.h" |
10 #include "base/strings/stringprintf.h" | 10 #include "base/strings/stringprintf.h" |
(...skipping 189 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
200 const char OobeUI::kScreenDeviceDisabled[] = "device-disabled"; | 200 const char OobeUI::kScreenDeviceDisabled[] = "device-disabled"; |
201 | 201 |
202 OobeUI::OobeUI(content::WebUI* web_ui, const GURL& url) | 202 OobeUI::OobeUI(content::WebUI* web_ui, const GURL& url) |
203 : WebUIController(web_ui), | 203 : WebUIController(web_ui), |
204 core_handler_(nullptr), | 204 core_handler_(nullptr), |
205 network_dropdown_handler_(nullptr), | 205 network_dropdown_handler_(nullptr), |
206 update_screen_handler_(nullptr), | 206 update_screen_handler_(nullptr), |
207 network_view_(nullptr), | 207 network_view_(nullptr), |
208 debugging_screen_actor_(nullptr), | 208 debugging_screen_actor_(nullptr), |
209 eula_view_(nullptr), | 209 eula_view_(nullptr), |
210 hid_detection_view_(nullptr), | 210 hid_detection_screen_actor_(nullptr), |
211 reset_screen_actor_(nullptr), | 211 reset_screen_actor_(nullptr), |
212 autolaunch_screen_actor_(nullptr), | 212 autolaunch_screen_actor_(nullptr), |
213 kiosk_enable_screen_actor_(nullptr), | 213 kiosk_enable_screen_actor_(nullptr), |
214 wrong_hwid_screen_actor_(nullptr), | 214 wrong_hwid_screen_actor_(nullptr), |
215 auto_enrollment_check_screen_actor_(nullptr), | 215 auto_enrollment_check_screen_actor_(nullptr), |
216 supervised_user_creation_screen_actor_(nullptr), | 216 supervised_user_creation_screen_actor_(nullptr), |
217 app_launch_splash_screen_actor_(nullptr), | 217 app_launch_splash_screen_actor_(nullptr), |
218 controller_pairing_screen_actor_(nullptr), | 218 controller_pairing_screen_actor_(nullptr), |
219 host_pairing_screen_actor_(nullptr), | 219 host_pairing_screen_actor_(nullptr), |
220 device_disabled_screen_actor_(nullptr), | 220 device_disabled_screen_actor_(nullptr), |
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
284 wrong_hwid_screen_actor_ = wrong_hwid_screen_handler; | 284 wrong_hwid_screen_actor_ = wrong_hwid_screen_handler; |
285 AddScreenHandler(wrong_hwid_screen_handler); | 285 AddScreenHandler(wrong_hwid_screen_handler); |
286 | 286 |
287 AutoEnrollmentCheckScreenHandler* auto_enrollment_check_screen_handler = | 287 AutoEnrollmentCheckScreenHandler* auto_enrollment_check_screen_handler = |
288 new AutoEnrollmentCheckScreenHandler(); | 288 new AutoEnrollmentCheckScreenHandler(); |
289 auto_enrollment_check_screen_actor_ = auto_enrollment_check_screen_handler; | 289 auto_enrollment_check_screen_actor_ = auto_enrollment_check_screen_handler; |
290 AddScreenHandler(auto_enrollment_check_screen_handler); | 290 AddScreenHandler(auto_enrollment_check_screen_handler); |
291 | 291 |
292 HIDDetectionScreenHandler* hid_detection_screen_handler = | 292 HIDDetectionScreenHandler* hid_detection_screen_handler = |
293 new HIDDetectionScreenHandler(core_handler_); | 293 new HIDDetectionScreenHandler(core_handler_); |
294 hid_detection_view_ = hid_detection_screen_handler; | 294 hid_detection_screen_actor_ = hid_detection_screen_handler; |
295 AddScreenHandler(hid_detection_screen_handler); | 295 AddScreenHandler(hid_detection_screen_handler); |
296 | 296 |
297 error_screen_handler_ = new ErrorScreenHandler(network_state_informer_); | 297 error_screen_handler_ = new ErrorScreenHandler(network_state_informer_); |
298 AddScreenHandler(error_screen_handler_); | 298 AddScreenHandler(error_screen_handler_); |
299 | 299 |
300 // Initialize ErrorScreen if it hasn't initialized. | 300 // Initialize ErrorScreen if it hasn't initialized. |
301 if (WizardController::default_controller()) { | 301 if (WizardController::default_controller()) { |
302 BaseScreen* screen = WizardController::default_controller()->GetScreen( | 302 BaseScreen* screen = WizardController::default_controller()->GetScreen( |
303 WizardController::kErrorScreenName); | 303 WizardController::kErrorScreenName); |
304 CHECK(screen); | 304 CHECK(screen); |
(...skipping 137 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
442 } | 442 } |
443 | 443 |
444 WrongHWIDScreenActor* OobeUI::GetWrongHWIDScreenActor() { | 444 WrongHWIDScreenActor* OobeUI::GetWrongHWIDScreenActor() { |
445 return wrong_hwid_screen_actor_; | 445 return wrong_hwid_screen_actor_; |
446 } | 446 } |
447 | 447 |
448 AutoEnrollmentCheckScreenActor* OobeUI::GetAutoEnrollmentCheckScreenActor() { | 448 AutoEnrollmentCheckScreenActor* OobeUI::GetAutoEnrollmentCheckScreenActor() { |
449 return auto_enrollment_check_screen_actor_; | 449 return auto_enrollment_check_screen_actor_; |
450 } | 450 } |
451 | 451 |
452 HIDDetectionView* OobeUI::GetHIDDetectionView() { | 452 HIDDetectionScreenActor* OobeUI::GetHIDDetectionScreenActor() { |
453 return hid_detection_view_; | 453 return hid_detection_screen_actor_; |
454 } | 454 } |
455 | 455 |
456 ControllerPairingScreenActor* OobeUI::GetControllerPairingScreenActor() { | 456 ControllerPairingScreenActor* OobeUI::GetControllerPairingScreenActor() { |
457 return controller_pairing_screen_actor_; | 457 return controller_pairing_screen_actor_; |
458 } | 458 } |
459 | 459 |
460 HostPairingScreenActor* OobeUI::GetHostPairingScreenActor() { | 460 HostPairingScreenActor* OobeUI::GetHostPairingScreenActor() { |
461 return host_pairing_screen_actor_; | 461 return host_pairing_screen_actor_; |
462 } | 462 } |
463 | 463 |
(...skipping 189 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
653 DCHECK(screen_ids_.count(screen)) | 653 DCHECK(screen_ids_.count(screen)) |
654 << "Screen should be registered in InitializeScreenMaps()"; | 654 << "Screen should be registered in InitializeScreenMaps()"; |
655 Screen new_screen = screen_ids_[screen]; | 655 Screen new_screen = screen_ids_[screen]; |
656 FOR_EACH_OBSERVER(Observer, | 656 FOR_EACH_OBSERVER(Observer, |
657 observer_list_, | 657 observer_list_, |
658 OnCurrentScreenChanged(current_screen_, new_screen)); | 658 OnCurrentScreenChanged(current_screen_, new_screen)); |
659 current_screen_ = new_screen; | 659 current_screen_ = new_screen; |
660 } | 660 } |
661 | 661 |
662 } // namespace chromeos | 662 } // namespace chromeos |
OLD | NEW |