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

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

Issue 19528007: [Autofill] Temporarily drop support for street-address autocomplete type. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Update tests that used the street-address autocomplete type Created 7 years, 5 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 | Annotate | Revision Log
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 #include "components/autofill/core/browser/form_structure.h" 5 #include "components/autofill/core/browser/form_structure.h"
6 6
7 #include <utility> 7 #include <utility>
8 8
9 #include "base/basictypes.h" 9 #include "base/basictypes.h"
10 #include "base/command_line.h" 10 #include "base/command_line.h"
(...skipping 192 matching lines...) Expand 10 before | Expand all | Expand 10 after
203 203
204 if (autocomplete_type == "family-name") 204 if (autocomplete_type == "family-name")
205 return NAME_LAST; 205 return NAME_LAST;
206 206
207 if (autocomplete_type == "honorific-suffix") 207 if (autocomplete_type == "honorific-suffix")
208 return NAME_SUFFIX; 208 return NAME_SUFFIX;
209 209
210 if (autocomplete_type == "organization") 210 if (autocomplete_type == "organization")
211 return COMPANY_NAME; 211 return COMPANY_NAME;
212 212
213 if (autocomplete_type == "street-address" || 213 if (autocomplete_type == "address-line1")
214 autocomplete_type == "address-line1")
215 return ADDRESS_HOME_LINE1; 214 return ADDRESS_HOME_LINE1;
216 215
217 if (autocomplete_type == "address-line2") 216 if (autocomplete_type == "address-line2")
218 return ADDRESS_HOME_LINE2; 217 return ADDRESS_HOME_LINE2;
219 218
220 if (autocomplete_type == "locality") 219 if (autocomplete_type == "locality")
221 return ADDRESS_HOME_CITY; 220 return ADDRESS_HOME_CITY;
222 221
223 if (autocomplete_type == "region") 222 if (autocomplete_type == "region")
224 return ADDRESS_HOME_STATE; 223 return ADDRESS_HOME_STATE;
(...skipping 999 matching lines...) Expand 10 before | Expand all | Expand 10 after
1224 AutofillType::FieldTypeGroup field_type_group = 1223 AutofillType::FieldTypeGroup field_type_group =
1225 AutofillType((*field)->type()).group(); 1224 AutofillType((*field)->type()).group();
1226 if (field_type_group == AutofillType::CREDIT_CARD) 1225 if (field_type_group == AutofillType::CREDIT_CARD)
1227 (*field)->set_section((*field)->section() + "-cc"); 1226 (*field)->set_section((*field)->section() + "-cc");
1228 else 1227 else
1229 (*field)->set_section((*field)->section() + "-default"); 1228 (*field)->set_section((*field)->section() + "-default");
1230 } 1229 }
1231 } 1230 }
1232 1231
1233 } // namespace autofill 1232 } // namespace autofill
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698