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

Side by Side Diff: chrome/browser/resources/options/autofill_edit_address_overlay.js

Issue 6930052: Revert 84320 - Autofill DOMUI Prefs should work with i18n phone numbers (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 9 years, 7 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) 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', 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 // The GUID of the loaded address. 9 // The GUID of the loaded address.
10 var guid; 10 var guid;
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
52 * Creates, decorates and initializes the multi-value lists for full name, 52 * Creates, decorates and initializes the multi-value lists for full name,
53 * phone, fax, and email. 53 * phone, fax, and email.
54 * @private 54 * @private
55 */ 55 */
56 createMultiValueLists_: function() { 56 createMultiValueLists_: function() {
57 var list = $('full-name-list'); 57 var list = $('full-name-list');
58 options.autofillOptions.AutofillValuesList.decorate(list); 58 options.autofillOptions.AutofillValuesList.decorate(list);
59 list.autoExpands = true; 59 list.autoExpands = true;
60 60
61 list = $('phone-list'); 61 list = $('phone-list');
62 options.autofillOptions.AutofillPhoneValuesList.decorate(list); 62 options.autofillOptions.AutofillValuesList.decorate(list);
63 list.autoExpands = true; 63 list.autoExpands = true;
64 64
65 list = $('fax-list'); 65 list = $('fax-list');
66 options.autofillOptions.AutofillFaxValuesList.decorate(list); 66 options.autofillOptions.AutofillValuesList.decorate(list);
67 list.autoExpands = true; 67 list.autoExpands = true;
68 68
69 list = $('email-list'); 69 list = $('email-list');
70 options.autofillOptions.AutofillValuesList.decorate(list); 70 options.autofillOptions.AutofillValuesList.decorate(list);
71 list.autoExpands = true; 71 list.autoExpands = true;
72 }, 72 },
73 73
74 /** 74 /**
75 * Updates the data model for the list named |listName| with the values from 75 * Updates the data model for the list named |listName| with the values from
76 * |entries|. 76 * |entries|.
(...skipping 215 matching lines...) Expand 10 before | Expand all | Expand 10 after
292 }; 292 };
293 293
294 AutofillEditAddressOverlay.loadAddress = function(address) { 294 AutofillEditAddressOverlay.loadAddress = function(address) {
295 AutofillEditAddressOverlay.getInstance().loadAddress_(address); 295 AutofillEditAddressOverlay.getInstance().loadAddress_(address);
296 }; 296 };
297 297
298 AutofillEditAddressOverlay.setTitle = function(title) { 298 AutofillEditAddressOverlay.setTitle = function(title) {
299 $('autofill-address-title').textContent = title; 299 $('autofill-address-title').textContent = title;
300 }; 300 };
301 301
302 AutofillEditAddressOverlay.setValidatedPhoneNumbers = function(numbers) {
303 AutofillEditAddressOverlay.getInstance().setMultiValueList_('phone-list',
304 numbers);
305 };
306
307 AutofillEditAddressOverlay.setValidatedFaxNumbers = function(numbers) {
308 AutofillEditAddressOverlay.getInstance().setMultiValueList_('fax-list',
309 numbers);
310 };
311
312 // Export 302 // Export
313 return { 303 return {
314 AutofillEditAddressOverlay: AutofillEditAddressOverlay 304 AutofillEditAddressOverlay: AutofillEditAddressOverlay
315 }; 305 };
316 }); 306 });
OLDNEW
« no previous file with comments | « chrome/browser/autofill/phone_number_i18n_unittest.cc ('k') | chrome/browser/resources/options/autofill_options_list.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698