Chromium Code Reviews| Index: chrome/browser/resources/settings/passwords_and_forms_page/autofill_section.js |
| diff --git a/chrome/browser/resources/settings/passwords_and_forms_page/autofill_section.js b/chrome/browser/resources/settings/passwords_and_forms_page/autofill_section.js |
| index eda403181df3b4e5655c21f108deb058e8ea2e3f..3cfa7102bf39ec613367cfb284658088b593d54f 100644 |
| --- a/chrome/browser/resources/settings/passwords_and_forms_page/autofill_section.js |
| +++ b/chrome/browser/resources/settings/passwords_and_forms_page/autofill_section.js |
| @@ -386,7 +386,12 @@ AutofillManagerImpl.prototype = { |
| */ |
| onMenuEditCreditCardTap_: function(e) { |
| e.preventDefault(); |
| - this.showCreditCardDialog_ = true; |
| + |
| + if (this.activeCreditCard.metadata.isLocal) |
|
hcarmona
2017/06/02 19:52:39
This logic was removed in http://crrev.com/2681143
|
| + this.showCreditCardDialog_ = true; |
| + else |
| + this.onRemoteEditCreditCardTap_(); |
| + |
| this.$.creditCardSharedMenu.close(); |
| }, |
| @@ -415,6 +420,16 @@ AutofillManagerImpl.prototype = { |
| this.$.creditCardSharedMenu.close(); |
| }, |
| + /** |
| + * The 3-dot menu should not be shown if the card is entirely remote. |
| + * @param {!chrome.autofillPrivate.AutofillMetadata} metadata |
| + * @return {boolean} |
| + * @private |
| + */ |
| + showDots_: function(metadata) { |
| + return !!(metadata.isLocal || metadata.isCached); |
| + }, |
| + |
| /** |
| * Returns true if the list exists and has items. |
| * @param {Array<Object>} list |