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 User pod row implementation. | 6 * @fileoverview User pod row implementation. |
7 */ | 7 */ |
8 | 8 |
9 cr.define('login', function() { | 9 cr.define('login', function() { |
10 /** | 10 /** |
(...skipping 1120 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1131 /** @override */ | 1131 /** @override */ |
1132 decorate: function() { | 1132 decorate: function() { |
1133 UserPod.prototype.decorate.call(this); | 1133 UserPod.prototype.decorate.call(this); |
1134 }, | 1134 }, |
1135 | 1135 |
1136 /** @override */ | 1136 /** @override */ |
1137 update: function() { | 1137 update: function() { |
1138 // TODO(noms): Use the actual profile avatar for local profiles once the | 1138 // TODO(noms): Use the actual profile avatar for local profiles once the |
1139 // new, non-pixellated avatars are available. | 1139 // new, non-pixellated avatars are available. |
1140 this.imageElement.src = this.user.emailAddress == '' ? | 1140 this.imageElement.src = this.user.emailAddress == '' ? |
1141 'chrome://theme/IDR_USER_MANAGER_DEFAULT_AVATAR' : | 1141 'chrome://theme/IDR_PROFILE_AVATAR_26' : |
1142 this.user.userImage; | 1142 this.user.userImage; |
1143 this.nameElement.textContent = this.user.displayName; | 1143 this.nameElement.textContent = this.user.displayName; |
1144 | 1144 |
1145 var isLockedUser = this.user.needsSignin; | 1145 var isLockedUser = this.user.needsSignin; |
1146 this.signinButtonElement.hidden = true; | 1146 this.signinButtonElement.hidden = true; |
1147 this.lockedIndicatorElement.hidden = !isLockedUser; | 1147 this.lockedIndicatorElement.hidden = !isLockedUser; |
1148 this.passwordElement.hidden = !isLockedUser; | 1148 this.passwordElement.hidden = !isLockedUser; |
1149 this.nameElement.hidden = isLockedUser; | 1149 this.nameElement.hidden = isLockedUser; |
1150 | 1150 |
1151 UserPod.prototype.updateActionBoxArea.call(this); | 1151 UserPod.prototype.updateActionBoxArea.call(this); |
(...skipping 1095 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2247 if (this.podsWithPendingImages_.length == 0) { | 2247 if (this.podsWithPendingImages_.length == 0) { |
2248 this.classList.remove('images-loading'); | 2248 this.classList.remove('images-loading'); |
2249 } | 2249 } |
2250 } | 2250 } |
2251 }; | 2251 }; |
2252 | 2252 |
2253 return { | 2253 return { |
2254 PodRow: PodRow | 2254 PodRow: PodRow |
2255 }; | 2255 }; |
2256 }); | 2256 }); |
OLD | NEW |