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

Side by Side Diff: components/autofill/core/browser/form_structure.h

Issue 2796873002: Sending autofill types for username fields in sign-in forms for improving username detection. (Closed)
Patch Set: Fix compilation error Created 3 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 unified diff | Download patch
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 #ifndef COMPONENTS_AUTOFILL_CORE_BROWSER_FORM_STRUCTURE_H_ 5 #ifndef COMPONENTS_AUTOFILL_CORE_BROWSER_FORM_STRUCTURE_H_
6 #define COMPONENTS_AUTOFILL_CORE_BROWSER_FORM_STRUCTURE_H_ 6 #define COMPONENTS_AUTOFILL_CORE_BROWSER_FORM_STRUCTURE_H_
7 7
8 #include <stddef.h> 8 #include <stddef.h>
9 9
10 #include <memory> 10 #include <memory>
(...skipping 208 matching lines...) Expand 10 before | Expand all | Expand 10 after
219 return has_author_specified_upi_vpa_hint_; 219 return has_author_specified_upi_vpa_hint_;
220 } 220 }
221 221
222 void set_upload_required(UploadRequired required) { 222 void set_upload_required(UploadRequired required) {
223 upload_required_ = required; 223 upload_required_ = required;
224 } 224 }
225 UploadRequired upload_required() const { return upload_required_; } 225 UploadRequired upload_required() const { return upload_required_; }
226 226
227 bool all_fields_are_passwords() const { return all_fields_are_passwords_; } 227 bool all_fields_are_passwords() const { return all_fields_are_passwords_; }
228 228
229 bool is_signin_upload() const { return is_signin_upload_; }
230 void set_is_signin_upload(bool is_signin_upload) {
231 is_signin_upload_ = is_signin_upload;
232 }
233
229 FormSignature form_signature() const { return form_signature_; } 234 FormSignature form_signature() const { return form_signature_; }
230 235
231 // Returns a FormData containing the data this form structure knows about. 236 // Returns a FormData containing the data this form structure knows about.
232 FormData ToFormData() const; 237 FormData ToFormData() const;
233 238
234 bool operator==(const FormData& form) const; 239 bool operator==(const FormData& form) const;
235 bool operator!=(const FormData& form) const; 240 bool operator!=(const FormData& form) const;
236 241
237 private: 242 private:
238 friend class AutofillMergeTest; 243 friend class AutofillMergeTest;
(...skipping 79 matching lines...) Expand 10 before | Expand all | Expand 10 after
318 323
319 // True if the form is a <form>. 324 // True if the form is a <form>.
320 bool is_form_tag_; 325 bool is_form_tag_;
321 326
322 // True if the form is made of unowned fields in a non checkout flow. 327 // True if the form is made of unowned fields in a non checkout flow.
323 bool is_formless_checkout_; 328 bool is_formless_checkout_;
324 329
325 // True if all form fields are password fields. 330 // True if all form fields are password fields.
326 bool all_fields_are_passwords_; 331 bool all_fields_are_passwords_;
327 332
333 // True if the form is submitted and has 2 fields: one text and one password
334 // field.
335 bool is_signin_upload_;
336
328 // The unique signature for this form, composed of the target url domain, 337 // The unique signature for this form, composed of the target url domain,
329 // the form name, and the form field names in a 64-bit hash. 338 // the form name, and the form field names in a 64-bit hash.
330 FormSignature form_signature_; 339 FormSignature form_signature_;
331 340
332 DISALLOW_COPY_AND_ASSIGN(FormStructure); 341 DISALLOW_COPY_AND_ASSIGN(FormStructure);
333 }; 342 };
334 343
335 } // namespace autofill 344 } // namespace autofill
336 345
337 #endif // COMPONENTS_AUTOFILL_CORE_BROWSER_FORM_STRUCTURE_H_ 346 #endif // COMPONENTS_AUTOFILL_CORE_BROWSER_FORM_STRUCTURE_H_
OLDNEW
« no previous file with comments | « components/autofill/core/browser/autofill_manager_unittest.cc ('k') | components/autofill/core/browser/form_structure.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698