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

Unified Diff: components/autofill/core/browser/form_structure.cc

Issue 21947003: [Autofill] Move FieldTypeGroup out of the AutofillType class. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase Created 7 years, 4 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 side-by-side diff with in-line comments
Download patch
Index: components/autofill/core/browser/form_structure.cc
diff --git a/components/autofill/core/browser/form_structure.cc b/components/autofill/core/browser/form_structure.cc
index 46d0dbc0d1363ea171f3b4349a63d9bf5268f3a0..3c49b4509aa9793d4b86b13beda09bd42989d240 100644
--- a/components/autofill/core/browser/form_structure.cc
+++ b/components/autofill/core/browser/form_structure.cc
@@ -1218,7 +1218,7 @@ void FormStructure::IdentifySections(bool has_author_specified_sections) {
// Forms often ask for multiple phone numbers -- e.g. both a daytime and
// evening phone number. Our phone number detection is also generally a
// little off. Hence, ignore this field type as a signal here.
- if (AutofillType(current_type).group() == AutofillType::PHONE_HOME)
+ if (AutofillType(current_type).group() == PHONE_HOME)
already_saw_current_type = false;
// Some forms have adjacent fields of the same type. Two common examples:
@@ -1250,9 +1250,8 @@ void FormStructure::IdentifySections(bool has_author_specified_sections) {
// This simplifies the section-aware logic in autofill_manager.cc.
for (std::vector<AutofillField*>::iterator field = fields_.begin();
field != fields_.end(); ++field) {
- AutofillType::FieldTypeGroup field_type_group =
- AutofillType((*field)->type()).group();
- if (field_type_group == AutofillType::CREDIT_CARD)
+ FieldTypeGroup field_type_group = AutofillType((*field)->type()).group();
+ if (field_type_group == CREDIT_CARD)
(*field)->set_section((*field)->section() + "-cc");
else
(*field)->set_section((*field)->section() + "-default");
« no previous file with comments | « components/autofill/core/browser/field_types.h ('k') | components/autofill/core/browser/personal_data_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698