| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "components/autofill/content/renderer/form_classifier.h" | 5 #include "components/autofill/content/renderer/form_classifier.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 | 8 |
| 9 #include "base/macros.h" | 9 #include "base/macros.h" |
| 10 #include "base/strings/string16.h" | 10 #include "base/strings/string16.h" |
| (...skipping 239 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 250 (found_signup_text_features && !found_signin_text_features)) { | 250 (found_signup_text_features && !found_signin_text_features)) { |
| 251 WebInputElement password_creation_field; | 251 WebInputElement password_creation_field; |
| 252 | 252 |
| 253 // TODO(crbug.com/618309): Improve local classifier to distinguish password | 253 // TODO(crbug.com/618309): Improve local classifier to distinguish password |
| 254 // creation and password usage fields on the change password forms. | 254 // creation and password usage fields on the change password forms. |
| 255 if (passwords.size() == 3) | 255 if (passwords.size() == 3) |
| 256 password_creation_field = passwords[1]; | 256 password_creation_field = passwords[1]; |
| 257 else | 257 else |
| 258 password_creation_field = passwords[0]; | 258 password_creation_field = passwords[0]; |
| 259 | 259 |
| 260 *generation_field = password_creation_field.nameForAutofill(); | 260 *generation_field = password_creation_field.nameForAutofill().utf16(); |
| 261 return true; | 261 return true; |
| 262 } | 262 } |
| 263 return false; | 263 return false; |
| 264 } | 264 } |
| 265 } | 265 } |
| OLD | NEW |