Chromium Code Reviews| OLD | NEW |
|---|---|
| 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.autofillOptions', function() { | 5 cr.define('options.autofillOptions', function() { |
| 6 /** @const */ var DeletableItem = options.DeletableItem; | 6 /** @const */ var DeletableItem = options.DeletableItem; |
| 7 /** @const */ var DeletableItemList = options.DeletableItemList; | 7 /** @const */ var DeletableItemList = options.DeletableItemList; |
| 8 /** @const */ var InlineEditableItem = options.InlineEditableItem; | 8 /** @const */ var InlineEditableItem = options.InlineEditableItem; |
| 9 /** @const */ var InlineEditableItemList = options.InlineEditableItemList; | 9 /** @const */ var InlineEditableItemList = options.InlineEditableItemList; |
| 10 | 10 |
| (...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 56 var label = this.ownerDocument.createElement('div'); | 56 var label = this.ownerDocument.createElement('div'); |
| 57 label.className = 'autofill-list-item'; | 57 label.className = 'autofill-list-item'; |
| 58 label.textContent = this.label; | 58 label.textContent = this.label; |
| 59 this.contentElement.appendChild(label); | 59 this.contentElement.appendChild(label); |
| 60 | 60 |
| 61 // The 'Edit' button. | 61 // The 'Edit' button. |
| 62 var editButtonEl = AutofillEditProfileButton( | 62 var editButtonEl = AutofillEditProfileButton( |
| 63 this.guid, | 63 this.guid, |
| 64 AutofillOptions.loadAddressEditor); | 64 AutofillOptions.loadAddressEditor); |
| 65 this.contentElement.appendChild(editButtonEl); | 65 this.contentElement.appendChild(editButtonEl); |
| 66 | |
| 67 this.closeButtonFocusable = true; | |
|
Dan Beam
2014/10/18 01:35:43
what's the benefit to this very specific accessor
| |
| 66 }, | 68 }, |
| 67 }; | 69 }; |
| 68 | 70 |
| 69 /** | 71 /** |
| 70 * Creates a new credit card list item. | 72 * Creates a new credit card list item. |
| 71 * @param {Array} entry An array of the form [guid, label, icon]. | 73 * @param {Array} entry An array of the form [guid, label, icon]. |
| 72 * @constructor | 74 * @constructor |
| 73 * @extends {options.DeletableItem} | 75 * @extends {options.DeletableItem} |
| 74 */ | 76 */ |
| 75 function CreditCardListItem(entry) { | 77 function CreditCardListItem(entry) { |
| (...skipping 25 matching lines...) Expand all Loading... | |
| 101 var icon = this.ownerDocument.createElement('img'); | 103 var icon = this.ownerDocument.createElement('img'); |
| 102 icon.src = this.icon; | 104 icon.src = this.icon; |
| 103 icon.alt = this.description; | 105 icon.alt = this.description; |
| 104 this.contentElement.appendChild(icon); | 106 this.contentElement.appendChild(icon); |
| 105 | 107 |
| 106 // The 'Edit' button. | 108 // The 'Edit' button. |
| 107 var editButtonEl = AutofillEditProfileButton( | 109 var editButtonEl = AutofillEditProfileButton( |
| 108 this.guid, | 110 this.guid, |
| 109 AutofillOptions.loadCreditCardEditor); | 111 AutofillOptions.loadCreditCardEditor); |
| 110 this.contentElement.appendChild(editButtonEl); | 112 this.contentElement.appendChild(editButtonEl); |
| 113 | |
| 114 this.closeButtonFocusable = true; | |
| 111 }, | 115 }, |
| 112 }; | 116 }; |
| 113 | 117 |
| 114 /** | 118 /** |
| 115 * Creates a new value list item. | 119 * Creates a new value list item. |
| 116 * @param {options.autofillOptions.AutofillValuesList} list The parent list of | 120 * @param {options.autofillOptions.AutofillValuesList} list The parent list of |
| 117 * this item. | 121 * this item. |
| 118 * @param {string} entry A string value. | 122 * @param {string} entry A string value. |
| 119 * @constructor | 123 * @constructor |
| 120 * @extends {options.InlineEditableItem} | 124 * @extends {options.InlineEditableItem} |
| (...skipping 440 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 561 CreditCardListItem: CreditCardListItem, | 565 CreditCardListItem: CreditCardListItem, |
| 562 ValuesListItem: ValuesListItem, | 566 ValuesListItem: ValuesListItem, |
| 563 NameListItem: NameListItem, | 567 NameListItem: NameListItem, |
| 564 AutofillAddressList: AutofillAddressList, | 568 AutofillAddressList: AutofillAddressList, |
| 565 AutofillCreditCardList: AutofillCreditCardList, | 569 AutofillCreditCardList: AutofillCreditCardList, |
| 566 AutofillValuesList: AutofillValuesList, | 570 AutofillValuesList: AutofillValuesList, |
| 567 AutofillNameValuesList: AutofillNameValuesList, | 571 AutofillNameValuesList: AutofillNameValuesList, |
| 568 AutofillPhoneValuesList: AutofillPhoneValuesList, | 572 AutofillPhoneValuesList: AutofillPhoneValuesList, |
| 569 }; | 573 }; |
| 570 }); | 574 }); |
| OLD | NEW |