Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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', function() { | 5 cr.define('options', function() { |
| 6 const OptionsPage = options.OptionsPage; | 6 const OptionsPage = options.OptionsPage; |
| 7 const ArrayDataModel = cr.ui.ArrayDataModel; | 7 const ArrayDataModel = cr.ui.ArrayDataModel; |
| 8 const ListSingleSelectionModel = cr.ui.ListSingleSelectionModel; | 8 const ListSingleSelectionModel = cr.ui.ListSingleSelectionModel; |
| 9 | 9 |
| 10 ///////////////////////////////////////////////////////////////////////////// | 10 ///////////////////////////////////////////////////////////////////////////// |
| (...skipping 28 matching lines...) Expand all Loading... | |
| 39 * @type {DeletableItemList} | 39 * @type {DeletableItemList} |
| 40 * @private | 40 * @private |
| 41 */ | 41 */ |
| 42 passwordExceptionsList_: null, | 42 passwordExceptionsList_: null, |
| 43 | 43 |
| 44 initializePage: function() { | 44 initializePage: function() { |
| 45 OptionsPage.prototype.initializePage.call(this); | 45 OptionsPage.prototype.initializePage.call(this); |
| 46 | 46 |
| 47 this.createSavedPasswordsList_(); | 47 this.createSavedPasswordsList_(); |
| 48 this.createPasswordExceptionsList_(); | 48 this.createPasswordExceptionsList_(); |
| 49 }, | |
| 49 | 50 |
| 51 didShowPage: function() { | |
|
stuartmorgan
2011/01/21 00:23:37
/** @inheritDoc */
James Hawkins
2011/01/21 00:37:33
Done.
| |
| 52 // Updating the password lists may cause a blocking platform dialog pop up | |
| 53 // (Mac, Linux), so we delay this operation until the page is shown. | |
| 50 chrome.send('updatePasswordLists'); | 54 chrome.send('updatePasswordLists'); |
|
stuartmorgan
2011/01/21 00:23:37
I assume this is okay to call more than once?
James Hawkins
2011/01/21 00:37:33
Correct.
| |
| 51 }, | 55 }, |
| 52 | 56 |
| 53 /** | 57 /** |
| 54 * Creates, decorates and initializes the saved passwords list. | 58 * Creates, decorates and initializes the saved passwords list. |
| 55 * @private | 59 * @private |
| 56 */ | 60 */ |
| 57 createSavedPasswordsList_: function() { | 61 createSavedPasswordsList_: function() { |
| 58 this.savedPasswordsList_ = $('saved-passwords-list'); | 62 this.savedPasswordsList_ = $('saved-passwords-list'); |
| 59 options.passwordManager.PasswordsList.decorate(this.savedPasswordsList_); | 63 options.passwordManager.PasswordsList.decorate(this.savedPasswordsList_); |
| 60 this.savedPasswordsList_.selectionModel = new ListSingleSelectionModel; | 64 this.savedPasswordsList_.selectionModel = new ListSingleSelectionModel; |
| (...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 133 PasswordManager.getInstance().setPasswordExceptionsList_(entries); | 137 PasswordManager.getInstance().setPasswordExceptionsList_(entries); |
| 134 }; | 138 }; |
| 135 | 139 |
| 136 // Export | 140 // Export |
| 137 return { | 141 return { |
| 138 PasswordManager: PasswordManager | 142 PasswordManager: PasswordManager |
| 139 }; | 143 }; |
| 140 | 144 |
| 141 }); | 145 }); |
| 142 | 146 |
| OLD | NEW |