Chromium Code Reviews| Index: components/autofill/content/renderer/password_autofill_agent.cc |
| diff --git a/components/autofill/content/renderer/password_autofill_agent.cc b/components/autofill/content/renderer/password_autofill_agent.cc |
| index 86c6bf030441a42d79d909db4e88f4b92f65b96e..dabe513cd490b0bd9b7f79ec29c5e52cbe6702c3 100644 |
| --- a/components/autofill/content/renderer/password_autofill_agent.cc |
| +++ b/components/autofill/content/renderer/password_autofill_agent.cc |
| @@ -185,6 +185,12 @@ bool FindFormInputElement( |
| if (input_element.isPasswordField() != is_password_field) |
| continue; |
| + // Avoid autofilling invisible password fields. |
| + if (input_element.isPasswordField() && |
| + IsInputElementHidden((blink::WebInputElement*)&input_element)) { |
|
vabr (Chromium)
2015/10/20 16:40:22
Please use IsWebNodeVisible. That will also get ri
Pritam Nikam
2015/10/22 09:00:08
Done.
|
| + continue; |
| + } |
| + |
| // For change password form with ambiguous or empty names keep only the |
| // first password field having |autocomplete='current-password'| attribute |
| // set. Also make sure we avoid keeping password fields having |