Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(471)

Side by Side Diff: ui/login/display_manager.js

Issue 904163003: Reset Screen moved to ScreenContext. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Include for GetNativeWindow added. Created 5 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « chrome/chrome_browser_chromeos.gypi ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 68 matching lines...) Expand 10 before | Expand all | Expand 10 after
79 /** @const */ var DISPLAY_TYPE = { 79 /** @const */ var DISPLAY_TYPE = {
80 UNKNOWN: 'unknown', 80 UNKNOWN: 'unknown',
81 OOBE: 'oobe', 81 OOBE: 'oobe',
82 LOGIN: 'login', 82 LOGIN: 'login',
83 LOCK: 'lock', 83 LOCK: 'lock',
84 USER_ADDING: 'user-adding', 84 USER_ADDING: 'user-adding',
85 APP_LAUNCH_SPLASH: 'app-launch-splash', 85 APP_LAUNCH_SPLASH: 'app-launch-splash',
86 DESKTOP_USER_MANAGER: 'login-add-user' 86 DESKTOP_USER_MANAGER: 'login-add-user'
87 }; 87 };
88 88
89 /** @const */ var USER_ACTION_ROLLBACK_TOGGLED = 'rollback-toggled';
90
89 cr.define('cr.ui.login', function() { 91 cr.define('cr.ui.login', function() {
90 var Bubble = cr.ui.Bubble; 92 var Bubble = cr.ui.Bubble;
91 93
92 /** 94 /**
93 * Maximum time in milliseconds to wait for step transition to finish. 95 * Maximum time in milliseconds to wait for step transition to finish.
94 * The value is used as the duration for ensureTransitionEndEvent below. 96 * The value is used as the duration for ensureTransitionEndEvent below.
95 * It needs to be inline with the step screen transition duration time 97 * It needs to be inline with the step screen transition duration time
96 * defined in css file. The current value in css is 200ms. To avoid emulated 98 * defined in css file. The current value in css is 200ms. To avoid emulated
97 * webkitTransitionEnd fired before real one, 250ms is used. 99 * webkitTransitionEnd fired before real one, 250ms is used.
98 * @const 100 * @const
(...skipping 272 matching lines...) Expand 10 before | Expand all | Expand 10 after
371 } else if (name == ACCELERATOR_KIOSK_ENABLE) { 373 } else if (name == ACCELERATOR_KIOSK_ENABLE) {
372 if (currentStepId == SCREEN_GAIA_SIGNIN || 374 if (currentStepId == SCREEN_GAIA_SIGNIN ||
373 currentStepId == SCREEN_ACCOUNT_PICKER) { 375 currentStepId == SCREEN_ACCOUNT_PICKER) {
374 chrome.send('toggleKioskEnableScreen'); 376 chrome.send('toggleKioskEnableScreen');
375 } 377 }
376 } else if (name == ACCELERATOR_VERSION) { 378 } else if (name == ACCELERATOR_VERSION) {
377 if (this.allowToggleVersion_) 379 if (this.allowToggleVersion_)
378 $('version-labels').hidden = !$('version-labels').hidden; 380 $('version-labels').hidden = !$('version-labels').hidden;
379 } else if (name == ACCELERATOR_RESET) { 381 } else if (name == ACCELERATOR_RESET) {
380 if (currentStepId == SCREEN_OOBE_RESET) 382 if (currentStepId == SCREEN_OOBE_RESET)
381 chrome.send('toggleRollbackOnResetScreen'); 383 $('reset').send(login.Screen.CALLBACK_USER_ACTED,
384 USER_ACTION_ROLLBACK_TOGGLED);
382 else if (RESET_AVAILABLE_SCREEN_GROUP.indexOf(currentStepId) != -1) 385 else if (RESET_AVAILABLE_SCREEN_GROUP.indexOf(currentStepId) != -1)
383 chrome.send('toggleResetScreen'); 386 chrome.send('toggleResetScreen');
384 } else if (name == ACCELERATOR_DEVICE_REQUISITION) { 387 } else if (name == ACCELERATOR_DEVICE_REQUISITION) {
385 if (this.isOobeUI()) 388 if (this.isOobeUI())
386 this.showDeviceRequisitionPrompt_(); 389 this.showDeviceRequisitionPrompt_();
387 } else if (name == ACCELERATOR_DEVICE_REQUISITION_REMORA) { 390 } else if (name == ACCELERATOR_DEVICE_REQUISITION_REMORA) {
388 if (this.isOobeUI()) 391 if (this.isOobeUI())
389 this.showDeviceRequisitionRemoraPrompt_( 392 this.showDeviceRequisitionRemoraPrompt_(
390 'deviceRequisitionRemoraPromptText', 'remora'); 393 'deviceRequisitionRemoraPromptText', 'remora');
391 } else if (name == ACCELERATOR_DEVICE_REQUISITION_SHARK) { 394 } else if (name == ACCELERATOR_DEVICE_REQUISITION_SHARK) {
(...skipping 674 matching lines...) Expand 10 before | Expand all | Expand 10 after
1066 */ 1069 */
1067 DisplayManager.refocusCurrentPod = function() { 1070 DisplayManager.refocusCurrentPod = function() {
1068 $('pod-row').refocusCurrentPod(); 1071 $('pod-row').refocusCurrentPod();
1069 }; 1072 };
1070 1073
1071 // Export 1074 // Export
1072 return { 1075 return {
1073 DisplayManager: DisplayManager 1076 DisplayManager: DisplayManager
1074 }; 1077 };
1075 }); 1078 });
OLDNEW
« no previous file with comments | « chrome/chrome_browser_chromeos.gypi ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698