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 /** | 5 /** |
6 * @fileoverview Display manager for WebUI OOBE and login. | 6 * @fileoverview Display manager for WebUI OOBE and login. |
7 */ | 7 */ |
8 | 8 |
9 // TODO(xiyuan): Find a better to share those constants. | 9 // TODO(xiyuan): Find a better to share those constants. |
10 /** @const */ var SCREEN_OOBE_NETWORK = 'connect'; | 10 /** @const */ var SCREEN_OOBE_NETWORK = 'connect'; |
(...skipping 288 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
299 handleAccelerator: function(name) { | 299 handleAccelerator: function(name) { |
300 var currentStepId = this.screens_[this.currentStep_]; | 300 var currentStepId = this.screens_[this.currentStep_]; |
301 if (name == ACCELERATOR_CANCEL) { | 301 if (name == ACCELERATOR_CANCEL) { |
302 if (this.currentScreen.cancel) { | 302 if (this.currentScreen.cancel) { |
303 this.currentScreen.cancel(); | 303 this.currentScreen.cancel(); |
304 } | 304 } |
305 } else if (name == ACCELERATOR_ENROLLMENT) { | 305 } else if (name == ACCELERATOR_ENROLLMENT) { |
306 if (currentStepId == SCREEN_GAIA_SIGNIN || | 306 if (currentStepId == SCREEN_GAIA_SIGNIN || |
307 currentStepId == SCREEN_ACCOUNT_PICKER) { | 307 currentStepId == SCREEN_ACCOUNT_PICKER) { |
308 chrome.send('toggleEnrollmentScreen'); | 308 chrome.send('toggleEnrollmentScreen'); |
309 } else if (currentStepId == SCREEN_OOBE_NETWORK || | |
310 currentStepId == SCREEN_OOBE_EULA) { | |
311 // In this case update check will be skipped and OOBE will | |
312 // proceed straight to enrollment screen when EULA is accepted. | |
313 chrome.send('skipUpdateEnrollAfterEula'); | |
314 } else if (currentStepId == SCREEN_OOBE_ENROLLMENT) { | 309 } else if (currentStepId == SCREEN_OOBE_ENROLLMENT) { |
315 // This accelerator is also used to manually cancel auto-enrollment. | 310 // This accelerator is also used to manually cancel auto-enrollment. |
316 if (this.currentScreen.cancelAutoEnrollment) | 311 if (this.currentScreen.cancelAutoEnrollment) |
317 this.currentScreen.cancelAutoEnrollment(); | 312 this.currentScreen.cancelAutoEnrollment(); |
318 } | 313 } |
319 } else if (name == ACCELERATOR_KIOSK_ENABLE) { | 314 } else if (name == ACCELERATOR_KIOSK_ENABLE) { |
320 if (currentStepId == SCREEN_GAIA_SIGNIN || | 315 if (currentStepId == SCREEN_GAIA_SIGNIN || |
321 currentStepId == SCREEN_ACCOUNT_PICKER) { | 316 currentStepId == SCREEN_ACCOUNT_PICKER) { |
322 chrome.send('toggleKioskEnableScreen'); | 317 chrome.send('toggleKioskEnableScreen'); |
323 } | 318 } |
(...skipping 671 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
995 */ | 990 */ |
996 DisplayManager.refocusCurrentPod = function() { | 991 DisplayManager.refocusCurrentPod = function() { |
997 $('pod-row').refocusCurrentPod(); | 992 $('pod-row').refocusCurrentPod(); |
998 }; | 993 }; |
999 | 994 |
1000 // Export | 995 // Export |
1001 return { | 996 return { |
1002 DisplayManager: DisplayManager | 997 DisplayManager: DisplayManager |
1003 }; | 998 }; |
1004 }); | 999 }); |
OLD | NEW |