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

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

Issue 3174028: DOMUI: Implement the base HTML for the 'Edit credit card' AutoFill overlay. (Closed)
Patch Set: Forgotten files. 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 24 matching lines...) Expand all
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) { 42 $('addAddressButton').onclick = function(event) {
43 OptionsPage.showOverlay('autoFillEditAddressOverlay'); 43 OptionsPage.showOverlay('autoFillEditAddressOverlay');
44 }; 44 };
45 $('addCreditCardButton').onclick = function(event) {
46 OptionsPage.showOverlay('autoFillEditCreditCardOverlay');
47 };
45 48
46 Preferences.getInstance().addEventListener('autofill.enabled', 49 Preferences.getInstance().addEventListener('autofill.enabled',
47 cr.bind(self.updateButtonState_, self)); 50 cr.bind(self.updateButtonState_, self));
48 }, 51 },
49 52
50 /** 53 /**
51 * Sets the enabled state of the button controls based on the current state 54 * Sets the enabled state of the button controls based on the current state
52 * of the |autoFillEnabled| checkbox. 55 * of the |autoFillEnabled| checkbox.
53 * @private 56 * @private
54 */ 57 */
(...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after
139 AutoFillOptions.getInstance().updateCreditCards_(creditCards); 142 AutoFillOptions.getInstance().updateCreditCards_(creditCards);
140 }; 143 };
141 144
142 // Export 145 // Export
143 return { 146 return {
144 AutoFillOptions: AutoFillOptions 147 AutoFillOptions: AutoFillOptions
145 }; 148 };
146 149
147 }); 150 });
148 151
OLDNEW
« no previous file with comments | « chrome/browser/resources/options/autofill_edit_creditcard_overlay.js ('k') | chrome/chrome_browser.gypi » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698