Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(133)

Side by Side Diff: chrome/browser/resources/options2/password_manager.js

Issue 9316086: Fix JavaScript errors in options2 (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 8
9 ///////////////////////////////////////////////////////////////////////////// 9 /////////////////////////////////////////////////////////////////////////////
10 // PasswordManager class: 10 // PasswordManager class:
(...skipping 163 matching lines...) Expand 10 before | Expand all | Expand 10 after
174 * from |entries|. 174 * from |entries|.
175 * @param {Array} entries The list of password exception data. 175 * @param {Array} entries The list of password exception data.
176 */ 176 */
177 setPasswordExceptionsList_: function(entries) { 177 setPasswordExceptionsList_: function(entries) {
178 this.passwordExceptionsList_.dataModel = new ArrayDataModel(entries); 178 this.passwordExceptionsList_.dataModel = new ArrayDataModel(entries);
179 this.updateListVisibility_(this.passwordExceptionsList_); 179 this.updateListVisibility_(this.passwordExceptionsList_);
180 }, 180 },
181 }; 181 };
182 182
183 /** 183 /**
184 * Call to remove a saved password. 184 * Remove a saved password.
James Hawkins 2012/02/03 01:28:24 Removes
Tyler Breisacher (Chromium) 2012/02/03 01:40:01 Done.
185 * @param rowIndex indicating the row to remove. 185 * @param {number} rowIndex indicating the row to remove.
186 */ 186 */
187 PasswordManager.removeSavedPassword = function(rowIndex) { 187 PasswordManager.removeSavedPassword = function(rowIndex) {
188 chrome.send('removeSavedPassword', [String(rowIndex)]); 188 chrome.send('removeSavedPassword', [String(rowIndex)]);
189 }; 189 };
190 190
191 /** 191 /**
192 * Call to remove a password exception. 192 * Removes a password exception.
193 * @param rowIndex indicating the row to remove. 193 * @param {number} rowIndex indicating the row to remove.
194 */ 194 */
195 PasswordManager.removePasswordException = function(rowIndex) { 195 PasswordManager.removePasswordException = function(rowIndex) {
196 chrome.send('removePasswordException', [String(rowIndex)]); 196 chrome.send('removePasswordException', [String(rowIndex)]);
197 }; 197 };
198 198
199 /** 199 /**
200 * Call to remove all saved passwords. 200 * Removes all saved passwords.
201 * @param tab contentType of the tab currently on.
202 */ 201 */
203 PasswordManager.removeAllPasswords = function() { 202 PasswordManager.removeAllPasswords = function() {
204 chrome.send('removeAllSavedPasswords'); 203 chrome.send('removeAllSavedPasswords');
205 }; 204 };
206 205
207 /** 206 /**
208 * Call to remove all saved passwords. 207 * Removes all password exceptions.
209 * @param tab contentType of the tab currently on.
210 */ 208 */
211 PasswordManager.removeAllPasswordExceptions = function() { 209 PasswordManager.removeAllPasswordExceptions = function() {
212 chrome.send('removeAllPasswordExceptions'); 210 chrome.send('removeAllPasswordExceptions');
213 }; 211 };
214 212
215 PasswordManager.setSavedPasswordsList = function(entries) { 213 PasswordManager.setSavedPasswordsList = function(entries) {
216 PasswordManager.getInstance().setSavedPasswordsList_(entries); 214 PasswordManager.getInstance().setSavedPasswordsList_(entries);
217 }; 215 };
218 216
219 PasswordManager.setPasswordExceptionsList = function(entries) { 217 PasswordManager.setPasswordExceptionsList = function(entries) {
220 PasswordManager.getInstance().setPasswordExceptionsList_(entries); 218 PasswordManager.getInstance().setPasswordExceptionsList_(entries);
221 }; 219 };
222 220
223 // Export 221 // Export
224 return { 222 return {
225 PasswordManager: PasswordManager 223 PasswordManager: PasswordManager
226 }; 224 };
227 225
228 }); 226 });
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698