| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 cr.define('options.accounts', function() { | 5 cr.define('options.accounts', function() { |
| 6 const List = cr.ui.List; | 6 const List = cr.ui.List; |
| 7 const ListItem = cr.ui.ListItem; | 7 const ListItem = cr.ui.ListItem; |
| 8 const ArrayDataModel = cr.ui.ArrayDataModel; | 8 const ArrayDataModel = cr.ui.ArrayDataModel; |
| 9 | 9 |
| 10 /** | 10 /** |
| (...skipping 173 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 184 emailNameBlock.appendChild(labelName); | 184 emailNameBlock.appendChild(labelName); |
| 185 emailNameBlock.title = this.user.owner ? | 185 emailNameBlock.title = this.user.owner ? |
| 186 localStrings.getStringF('username_format', this.user.email) : | 186 localStrings.getStringF('username_format', this.user.email) : |
| 187 this.user.email; | 187 this.user.email; |
| 188 | 188 |
| 189 this.appendChild(this.icon_); | 189 this.appendChild(this.icon_); |
| 190 this.appendChild(emailNameBlock); | 190 this.appendChild(emailNameBlock); |
| 191 | 191 |
| 192 if (!this.user.owner) { | 192 if (!this.user.owner) { |
| 193 var removeButton = this.ownerDocument.createElement('button'); | 193 var removeButton = this.ownerDocument.createElement('button'); |
| 194 removeButton.classList.add('raw-button'); | 194 removeButton.className = |
| 195 removeButton.classList.add('remove-user-button'); | 195 'raw-button remove-user-button custom-appearance'; |
| 196 this.appendChild(removeButton); | 196 this.appendChild(removeButton); |
| 197 } | 197 } |
| 198 }, | 198 }, |
| 199 | 199 |
| 200 /** | 200 /** |
| 201 * Reloads user picture. | 201 * Reloads user picture. |
| 202 */ | 202 */ |
| 203 updatePicture: function() { | 203 updatePicture: function() { |
| 204 this.icon_.src = 'chrome://userimage/' + this.user.email + | 204 this.icon_.src = 'chrome://userimage/' + this.user.email + |
| 205 '?id=' + (new Date()).getTime(); | 205 '?id=' + (new Date()).getTime(); |
| 206 } | 206 } |
| 207 }; | 207 }; |
| 208 | 208 |
| 209 return { | 209 return { |
| 210 UserList: UserList | 210 UserList: UserList |
| 211 }; | 211 }; |
| 212 }); | 212 }); |
| OLD | NEW |