| 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 /** | 5 /** |
| 6 * @fileoverview Login UI header bar implementation. | 6 * @fileoverview Login UI header bar implementation. |
| 7 */ | 7 */ |
| 8 | 8 |
| 9 cr.define('login', function() { | 9 cr.define('login', function() { |
| 10 /** | 10 /** |
| (...skipping 158 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 169 | 169 |
| 170 /** | 170 /** |
| 171 * Updates visibility state of action buttons. | 171 * Updates visibility state of action buttons. |
| 172 * @private | 172 * @private |
| 173 */ | 173 */ |
| 174 updateUI_: function() { | 174 updateUI_: function() { |
| 175 var gaiaIsActive = (this.signinUIState_ == SIGNIN_UI_STATE.GAIA_SIGNIN); | 175 var gaiaIsActive = (this.signinUIState_ == SIGNIN_UI_STATE.GAIA_SIGNIN); |
| 176 var accountPickerIsActive = | 176 var accountPickerIsActive = |
| 177 (this.signinUIState_ == SIGNIN_UI_STATE.ACCOUNT_PICKER); | 177 (this.signinUIState_ == SIGNIN_UI_STATE.ACCOUNT_PICKER); |
| 178 var managedUserCreationDialogIsActive = | 178 var managedUserCreationDialogIsActive = |
| 179 (this.signinUIState_ == SIGNIN_UI_STATE.MANAGED_USER_CREATION_DIALOG); | 179 (this.signinUIState_ == SIGNIN_UI_STATE.MANAGED_USER_CREATION_FLOW); |
| 180 var wrongHWIDWarningIsActive = | 180 var wrongHWIDWarningIsActive = |
| 181 (this.signinUIState_ == SIGNIN_UI_STATE.WRONG_HWID_WARNING); | 181 (this.signinUIState_ == SIGNIN_UI_STATE.WRONG_HWID_WARNING); |
| 182 | 182 |
| 183 $('add-user-button').hidden = !accountPickerIsActive; | 183 $('add-user-button').hidden = !accountPickerIsActive; |
| 184 $('cancel-add-user-button').hidden = accountPickerIsActive || | 184 $('cancel-add-user-button').hidden = accountPickerIsActive || |
| 185 !this.allowCancel_ || | 185 !this.allowCancel_ || |
| 186 wrongHWIDWarningIsActive; | 186 wrongHWIDWarningIsActive; |
| 187 $('guest-user-header-bar-item').hidden = gaiaIsActive || | 187 $('guest-user-header-bar-item').hidden = gaiaIsActive || |
| 188 managedUserCreationDialogIsActive || | 188 managedUserCreationDialogIsActive || |
| 189 !this.showGuest_ || | 189 !this.showGuest_ || |
| (...skipping 30 matching lines...) Expand all Loading... |
| 220 this.classList.remove('login-header-bar-animate-fast'); | 220 this.classList.remove('login-header-bar-animate-fast'); |
| 221 this.classList.add('login-header-bar-animate-slow'); | 221 this.classList.add('login-header-bar-animate-slow'); |
| 222 this.classList.remove('login-header-bar-hidden'); | 222 this.classList.remove('login-header-bar-hidden'); |
| 223 }, | 223 }, |
| 224 }; | 224 }; |
| 225 | 225 |
| 226 return { | 226 return { |
| 227 HeaderBar: HeaderBar | 227 HeaderBar: HeaderBar |
| 228 }; | 228 }; |
| 229 }); | 229 }); |
| OLD | NEW |