summaryrefslogtreecommitdiffstats
path: root/chrome/browser/autofill/autofill_external_delegate.cc
diff options
context:
space:
mode:
authorcsharp@chromium.org <csharp@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-04-27 14:25:08 +0000
committercsharp@chromium.org <csharp@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-04-27 14:25:08 +0000
commitecd661e3c734d302fe3b84d41e34e600ef4e4657 (patch)
tree7742ea93bc11fafadd8ed2ce4c265f3fadbcbc4f /chrome/browser/autofill/autofill_external_delegate.cc
parente66be851058585b4cc2fb33351d193cd37a4d588 (diff)
downloadchromium_src-ecd661e3c734d302fe3b84d41e34e600ef4e4657.zip
chromium_src-ecd661e3c734d302fe3b84d41e34e600ef4e4657.tar.gz
chromium_src-ecd661e3c734d302fe3b84d41e34e600ef4e4657.tar.bz2
New Autofill UI uses ID for password
The new Autofill UI uses field IDs to determine which values should be handled by the password manager or the default Autofill manager. BUG=51644 TEST= Review URL: http://codereview.chromium.org/10230005 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@134266 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/autofill/autofill_external_delegate.cc')
-rw-r--r--chrome/browser/autofill/autofill_external_delegate.cc10
1 files changed, 3 insertions, 7 deletions
diff --git a/chrome/browser/autofill/autofill_external_delegate.cc b/chrome/browser/autofill/autofill_external_delegate.cc
index 08ce18a..98ec1b4 100644
--- a/chrome/browser/autofill/autofill_external_delegate.cc
+++ b/chrome/browser/autofill/autofill_external_delegate.cc
@@ -37,8 +37,7 @@ AutofillExternalDelegate::AutofillExternalDelegate(
void AutofillExternalDelegate::SelectAutofillSuggestionAtIndex(int unique_id,
int list_index) {
- if (password_autofill_manager_.DidSelectAutofillSuggestion(
- autofill_query_field_))
+ if (unique_id == WebAutofillClient::MenuItemIDPasswordEntry)
return;
if (list_index == suggestions_options_index_ ||
@@ -185,7 +184,8 @@ bool AutofillExternalDelegate::DidAcceptAutofillSuggestions(
RenderViewHost* host =
tab_contents_wrapper_->web_contents()->GetRenderViewHost();
host->Send(new AutofillMsg_ClearForm(host->GetRoutingID()));
- } else if (password_autofill_manager_.DidAcceptAutofillSuggestion(
+ } else if (unique_id == WebAutofillClient::MenuItemIDPasswordEntry &&
+ password_autofill_manager_.DidAcceptAutofillSuggestion(
autofill_query_field_, value)) {
// DidAcceptAutofillSuggestion has already handled the work to fill in
// the page as required.
@@ -206,10 +206,6 @@ bool AutofillExternalDelegate::DidAcceptAutofillSuggestions(
}
void AutofillExternalDelegate::ClearPreviewedForm() {
- if (password_autofill_manager_.DidClearAutofillSelection(
- autofill_query_field_))
- return;
-
RenderViewHost* host =
tab_contents_wrapper_->web_contents()->GetRenderViewHost();
host->Send(new AutofillMsg_ClearPreviewedForm(host->GetRoutingID()));