| Index: components/autofill/content/renderer/autofill_agent.cc
|
| diff --git a/components/autofill/content/renderer/autofill_agent.cc b/components/autofill/content/renderer/autofill_agent.cc
|
| index 8a9350e9304bc369045479377850335096a0421e..02bfd51ab328169b849314e565b89fe6a74c14b6 100644
|
| --- a/components/autofill/content/renderer/autofill_agent.cc
|
| +++ b/components/autofill/content/renderer/autofill_agent.cc
|
| @@ -610,7 +610,7 @@ void AutofillAgent::ShowSuggestions(const WebFormControlElement& element,
|
|
|
| const WebInputElement* input_element = toWebInputElement(&element);
|
| if (input_element) {
|
| - if (!input_element->isTextField() || input_element->isPasswordField())
|
| + if (!input_element->isTextField())
|
| return;
|
| if (!options.datalist_only && !input_element->suggestedValue().isEmpty())
|
| return;
|
| @@ -643,6 +643,11 @@ void AutofillAgent::ShowSuggestions(const WebFormControlElement& element,
|
| return;
|
| }
|
|
|
| + // Password field elements should only have suggestions shown by the password
|
| + // autofill agent.
|
| + if (input_element && input_element->isPasswordField())
|
| + return;
|
| +
|
| // If autocomplete is disabled at the field level, ensure that the native
|
| // UI won't try to show a warning, since that may conflict with a custom
|
| // popup. Note that we cannot use the WebKit method element.autoComplete()
|
|
|