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 23 matching lines...) Expand all Loading... |
34 */ | 34 */ |
35 savedPasswordsList_: null, | 35 savedPasswordsList_: null, |
36 | 36 |
37 /** | 37 /** |
38 * The password exceptions list. | 38 * The password exceptions list. |
39 * @type {DeletableItemList} | 39 * @type {DeletableItemList} |
40 * @private | 40 * @private |
41 */ | 41 */ |
42 passwordExceptionsList_: null, | 42 passwordExceptionsList_: null, |
43 | 43 |
| 44 /** @inheritDoc */ |
44 initializePage: function() { | 45 initializePage: function() { |
45 OptionsPage.prototype.initializePage.call(this); | 46 OptionsPage.prototype.initializePage.call(this); |
46 | 47 |
47 this.createSavedPasswordsList_(); | 48 this.createSavedPasswordsList_(); |
48 this.createPasswordExceptionsList_(); | 49 this.createPasswordExceptionsList_(); |
| 50 }, |
49 | 51 |
| 52 /** @inheritDoc */ |
| 53 didShowPage: function() { |
| 54 // Updating the password lists may cause a blocking platform dialog pop up |
| 55 // (Mac, Linux), so we delay this operation until the page is shown. |
50 chrome.send('updatePasswordLists'); | 56 chrome.send('updatePasswordLists'); |
51 }, | 57 }, |
52 | 58 |
53 /** | 59 /** |
54 * Creates, decorates and initializes the saved passwords list. | 60 * Creates, decorates and initializes the saved passwords list. |
55 * @private | 61 * @private |
56 */ | 62 */ |
57 createSavedPasswordsList_: function() { | 63 createSavedPasswordsList_: function() { |
58 this.savedPasswordsList_ = $('saved-passwords-list'); | 64 this.savedPasswordsList_ = $('saved-passwords-list'); |
59 options.passwordManager.PasswordsList.decorate(this.savedPasswordsList_); | 65 options.passwordManager.PasswordsList.decorate(this.savedPasswordsList_); |
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
133 PasswordManager.getInstance().setPasswordExceptionsList_(entries); | 139 PasswordManager.getInstance().setPasswordExceptionsList_(entries); |
134 }; | 140 }; |
135 | 141 |
136 // Export | 142 // Export |
137 return { | 143 return { |
138 PasswordManager: PasswordManager | 144 PasswordManager: PasswordManager |
139 }; | 145 }; |
140 | 146 |
141 }); | 147 }); |
142 | 148 |
OLD | NEW |