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

Unified Diff: components/autofill/core/browser/autofill_external_delegate.cc

Issue 223133003: Allow deleting autofill password suggestions on Shift+Delete (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: bug fixed Created 6 years, 8 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 side-by-side diff with in-line comments
Download patch
Index: components/autofill/core/browser/autofill_external_delegate.cc
diff --git a/components/autofill/core/browser/autofill_external_delegate.cc b/components/autofill/core/browser/autofill_external_delegate.cc
index f435ceb8e23563face4edc083b1d815f12adcca7..d966a454dd0bdfc2cde37234e5c93392adc4e7ff 100644
--- a/components/autofill/core/browser/autofill_external_delegate.cc
+++ b/components/autofill/core/browser/autofill_external_delegate.cc
@@ -200,10 +200,15 @@ void AutofillExternalDelegate::DidAcceptSuggestion(const base::string16& value,
void AutofillExternalDelegate::RemoveSuggestion(const base::string16& value,
int identifier) {
- if (identifier > 0)
+ if (identifier > 0) {
manager_->RemoveAutofillProfileOrCreditCard(identifier);
- else
+ } else if (identifier == POPUP_ITEM_ID_PASSWORD_ENTRY) {
+ bool success =
+ password_manager_.RemovePasswordSuggestion(query_field_, value);
+ DCHECK(success);
+ } else {
Ilya Sherman 2014/04/09 06:33:05 nit: Please DCHECK that the identifier is for an a
rchtara 2014/04/09 13:52:43 Done.
manager_->RemoveAutocompleteEntry(query_field_.name, value);
+ }
}
void AutofillExternalDelegate::DidEndTextFieldEditing() {

Powered by Google App Engine
This is Rietveld 408576698