| 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 3151 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3162 for (var i = 0; i < this.apps_.length; ++i) | 3162 for (var i = 0; i < this.apps_.length; ++i) |
| 3163 this.addUserPod(this.apps_[i]); | 3163 this.addUserPod(this.apps_[i]); |
| 3164 } | 3164 } |
| 3165 | 3165 |
| 3166 // Make sure we eventually show the pod row, even if some image is stuck. | 3166 // Make sure we eventually show the pod row, even if some image is stuck. |
| 3167 setTimeout(function() { | 3167 setTimeout(function() { |
| 3168 $('pod-row').classList.remove('images-loading'); | 3168 $('pod-row').classList.remove('images-loading'); |
| 3169 this.smallPodsContainer.classList.remove('images-loading'); | 3169 this.smallPodsContainer.classList.remove('images-loading'); |
| 3170 this.topMask.classList.remove('images-loading'); | 3170 this.topMask.classList.remove('images-loading'); |
| 3171 this.bottomMask.classList.remove('images-loading'); | 3171 this.bottomMask.classList.remove('images-loading'); |
| 3172 }, POD_ROW_IMAGES_LOAD_TIMEOUT_MS); | 3172 }.bind(this), POD_ROW_IMAGES_LOAD_TIMEOUT_MS); |
| 3173 | 3173 |
| 3174 var isAccountPicker = $('login-header-bar').signinUIState == | 3174 var isAccountPicker = $('login-header-bar').signinUIState == |
| 3175 SIGNIN_UI_STATE.ACCOUNT_PICKER; | 3175 SIGNIN_UI_STATE.ACCOUNT_PICKER; |
| 3176 | 3176 |
| 3177 // Immediately recalculate pods layout only when current UI is account | 3177 // Immediately recalculate pods layout only when current UI is account |
| 3178 // picker. Otherwise postpone it. | 3178 // picker. Otherwise postpone it. |
| 3179 if (isAccountPicker) { | 3179 if (isAccountPicker) { |
| 3180 this.placePods_(); | 3180 this.placePods_(); |
| 3181 this.maybePreselectPod(); | 3181 this.maybePreselectPod(); |
| 3182 | 3182 |
| (...skipping 1514 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4697 if (pod && pod.multiProfilesPolicyApplied) { | 4697 if (pod && pod.multiProfilesPolicyApplied) { |
| 4698 pod.userTypeBubbleElement.classList.remove('bubble-shown'); | 4698 pod.userTypeBubbleElement.classList.remove('bubble-shown'); |
| 4699 } | 4699 } |
| 4700 } | 4700 } |
| 4701 }; | 4701 }; |
| 4702 | 4702 |
| 4703 return { | 4703 return { |
| 4704 PodRow: PodRow | 4704 PodRow: PodRow |
| 4705 }; | 4705 }; |
| 4706 }); | 4706 }); |
| OLD | NEW |