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

Side by Side Diff: chrome/browser/resources/options/autofill_edit_address_overlay.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
(Empty)
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
3 // found in the LICENSE file.
4
5 cr.define('options', function() {
6 const OptionsPage = options.OptionsPage;
7
8 /**
9 * AutoFillEditAddressOverlay class
10 * Encapsulated handling of the 'Add Page' overlay page.
11 * @class
12 */
13 function AutoFillEditAddressOverlay() {
14 OptionsPage.call(this, 'autoFillEditAddressOverlay',
15 templateData.autoFillEditAddressTitle,
16 'autoFillEditAddressOverlay');
17 }
18
19 cr.addSingletonGetter(AutoFillEditAddressOverlay);
20
21 AutoFillEditAddressOverlay.prototype = {
22 __proto__: OptionsPage.prototype,
23
24 /**
25 * Initializes the page.
26 */
27 initializePage: function() {
28 OptionsPage.prototype.initializePage.call(this);
29
30 var self = this;
31 $('autoFillEditAddressCancelButton').onclick = function(event) {
32 self.dismissOverlay_();
33 }
34 },
35
36 /**
37 * Clears any uncommited input, and dismisses the overlay.
38 * @private
39 */
40 dismissOverlay_: function() {
41 $('fullName').value = '';
42 $('companyName').value = '';
43 $('addrLine1').value = '';
44 $('addrLine2').value = '';
45 $('city').value = '';
46 $('state').value = '';
47 $('zipCode').value = '';
48 $('phone').value = '';
49 $('fax').value = '';
50 $('email').value = '';
51 OptionsPage.clearOverlays();
52 },
53
54 };
55
56 // Export
57 return {
58 AutoFillEditAddressOverlay: AutoFillEditAddressOverlay
59 };
60
61 });
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698