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

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

Issue 3157027: DOMUI: Add the basic HTML for the 'Edit Address' AutoFill overlay. (Closed)
Patch Set: Review fixes 2. Created 10 years, 4 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
OLDNEW
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 var OptionsPage = options.OptionsPage; 6 var OptionsPage = options.OptionsPage;
7 7
8 // The offset of the first profile in either the address list or the credit 8 // The offset of the first profile in either the address list or the credit
9 // card list. Consists of the header and the horizontal rule. 9 // card list. Consists of the header and the horizontal rule.
10 const profileOffset = 2; 10 const profileOffset = 2;
(...skipping 21 matching lines...) Expand all
32 AutoFillOptions.prototype = { 32 AutoFillOptions.prototype = {
33 __proto__: OptionsPage.prototype, 33 __proto__: OptionsPage.prototype,
34 34
35 initializePage: function() { 35 initializePage: function() {
36 OptionsPage.prototype.initializePage.call(this); 36 OptionsPage.prototype.initializePage.call(this);
37 37
38 var self = this; 38 var self = this;
39 $('profileList').onchange = function(event) { 39 $('profileList').onchange = function(event) {
40 self.updateRemoveButtonState_(); 40 self.updateRemoveButtonState_();
41 }; 41 };
42 $('addAddressButton').onclick = function(event) {
43 OptionsPage.showOverlay('autoFillEditAddressOverlay');
44 };
42 45
43 Preferences.getInstance().addEventListener('autofill.enabled', 46 Preferences.getInstance().addEventListener('autofill.enabled',
44 cr.bind(self.updateButtonState_, self)); 47 cr.bind(self.updateButtonState_, self));
45 }, 48 },
46 49
47 /** 50 /**
48 * Sets the enabled state of the button controls based on the current state 51 * Sets the enabled state of the button controls based on the current state
49 * of the |autoFillEnabled| checkbox. 52 * of the |autoFillEnabled| checkbox.
50 * @private 53 * @private
51 */ 54 */
(...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after
136 AutoFillOptions.getInstance().updateCreditCards_(creditCards); 139 AutoFillOptions.getInstance().updateCreditCards_(creditCards);
137 }; 140 };
138 141
139 // Export 142 // Export
140 return { 143 return {
141 AutoFillOptions: AutoFillOptions 144 AutoFillOptions: AutoFillOptions
142 }; 145 };
143 146
144 }); 147 });
145 148
OLDNEW
« no previous file with comments | « chrome/browser/resources/options/autofill_edit_address_overlay.js ('k') | chrome/chrome_browser.gypi » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698