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

Side by Side Diff: trunk/src/components/autofill/core/browser/address_i18n.cc

Issue 387123004: Revert 282726 "Reland "Use upstream libaddressinput in Chrome."" (Closed) Base URL: svn://svn.chromium.org/chrome/
Patch Set: Created 6 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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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/address_i18n.h" 5 #include "components/autofill/core/browser/address_i18n.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/callback.h" 8 #include "base/callback.h"
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "base/strings/string_split.h" 10 #include "base/strings/string_split.h"
11 #include "base/strings/utf_string_conversions.h" 11 #include "base/strings/utf_string_conversions.h"
12 #include "components/autofill/core/browser/autofill_profile.h" 12 #include "components/autofill/core/browser/autofill_profile.h"
13 #include "components/autofill/core/browser/autofill_type.h" 13 #include "components/autofill/core/browser/autofill_type.h"
14 #include "third_party/libaddressinput/src/cpp/include/libaddressinput/address_da ta.h" 14 #include "third_party/libaddressinput/chromium/cpp/include/libaddressinput/addre ss_data.h"
15 15
16 namespace autofill { 16 namespace autofill {
17 namespace i18n { 17 namespace i18n {
18 18
19 namespace { 19 namespace {
20 20
21 base::string16 GetInfoHelper(const AutofillProfile& profile, 21 base::string16 GetInfoHelper(const AutofillProfile& profile,
22 const std::string& app_locale, 22 const std::string& app_locale,
23 const AutofillType& type) { 23 const AutofillType& type) {
24 return profile.GetInfo(type, app_locale); 24 return profile.GetInfo(type, app_locale);
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
57 CreateAddressDataFromAutofillProfile(const AutofillProfile& profile, 57 CreateAddressDataFromAutofillProfile(const AutofillProfile& profile,
58 const std::string& app_locale) { 58 const std::string& app_locale) {
59 scoped_ptr< ::i18n::addressinput::AddressData> address_data = 59 scoped_ptr< ::i18n::addressinput::AddressData> address_data =
60 i18n::CreateAddressData(base::Bind(&GetInfoHelper, profile, app_locale)); 60 i18n::CreateAddressData(base::Bind(&GetInfoHelper, profile, app_locale));
61 address_data->language_code = profile.language_code(); 61 address_data->language_code = profile.language_code();
62 return address_data.Pass(); 62 return address_data.Pass();
63 } 63 }
64 64
65 } // namespace i18n 65 } // namespace i18n
66 } // namespace autofill 66 } // namespace autofill
OLDNEW
« no previous file with comments | « trunk/src/components/autofill/core/browser/BUILD.gn ('k') | trunk/src/components/autofill/core/browser/autofill_country.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698