| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 "chrome/browser/ui/webui/options/autofill_options_handler.h" | 5 #include "chrome/browser/ui/webui/options/autofill_options_handler.h" |
| 6 | 6 |
| 7 #include <vector> | 7 #include <vector> |
| 8 | 8 |
| 9 #include "base/bind.h" | 9 #include "base/bind.h" |
| 10 #include "base/bind_helpers.h" | 10 #include "base/bind_helpers.h" |
| 11 #include "base/guid.h" | 11 #include "base/guid.h" |
| 12 #include "base/logging.h" | 12 #include "base/logging.h" |
| 13 #include "base/strings/string16.h" | 13 #include "base/strings/string16.h" |
| 14 #include "base/strings/string_number_conversions.h" | 14 #include "base/strings/string_number_conversions.h" |
| 15 #include "base/strings/utf_string_conversions.h" | 15 #include "base/strings/utf_string_conversions.h" |
| 16 #include "base/values.h" | 16 #include "base/values.h" |
| 17 #include "chrome/browser/autofill/personal_data_manager_factory.h" | 17 #include "chrome/browser/autofill/personal_data_manager_factory.h" |
| 18 #include "chrome/browser/browser_process.h" | 18 #include "chrome/browser/browser_process.h" |
| 19 #include "chrome/browser/profiles/profile.h" | 19 #include "chrome/browser/profiles/profile.h" |
| 20 #include "chrome/browser/ui/autofill/country_combobox_model.h" | 20 #include "chrome/browser/ui/autofill/country_combobox_model.h" |
| 21 #include "chrome/common/url_constants.h" | 21 #include "chrome/common/url_constants.h" |
| 22 #include "chrome/grit/generated_resources.h" |
| 22 #include "components/autofill/core/browser/autofill_country.h" | 23 #include "components/autofill/core/browser/autofill_country.h" |
| 23 #include "components/autofill/core/browser/autofill_profile.h" | 24 #include "components/autofill/core/browser/autofill_profile.h" |
| 24 #include "components/autofill/core/browser/credit_card.h" | 25 #include "components/autofill/core/browser/credit_card.h" |
| 25 #include "components/autofill/core/browser/personal_data_manager.h" | 26 #include "components/autofill/core/browser/personal_data_manager.h" |
| 26 #include "components/autofill/core/browser/phone_number_i18n.h" | 27 #include "components/autofill/core/browser/phone_number_i18n.h" |
| 27 #include "components/autofill/core/common/autofill_constants.h" | 28 #include "components/autofill/core/common/autofill_constants.h" |
| 28 #include "content/public/browser/web_ui.h" | 29 #include "content/public/browser/web_ui.h" |
| 29 #include "grit/components_strings.h" | 30 #include "grit/components_strings.h" |
| 30 #include "grit/generated_resources.h" | |
| 31 #include "third_party/libaddressinput/messages.h" | 31 #include "third_party/libaddressinput/messages.h" |
| 32 #include "third_party/libaddressinput/src/cpp/include/libaddressinput/address_ui
.h" | 32 #include "third_party/libaddressinput/src/cpp/include/libaddressinput/address_ui
.h" |
| 33 #include "third_party/libaddressinput/src/cpp/include/libaddressinput/address_ui
_component.h" | 33 #include "third_party/libaddressinput/src/cpp/include/libaddressinput/address_ui
_component.h" |
| 34 #include "third_party/libaddressinput/src/cpp/include/libaddressinput/localizati
on.h" | 34 #include "third_party/libaddressinput/src/cpp/include/libaddressinput/localizati
on.h" |
| 35 #include "ui/base/l10n/l10n_util.h" | 35 #include "ui/base/l10n/l10n_util.h" |
| 36 #include "ui/base/webui/web_ui_util.h" | 36 #include "ui/base/webui/web_ui_util.h" |
| 37 | 37 |
| 38 using autofill::AutofillCountry; | 38 using autofill::AutofillCountry; |
| 39 using autofill::AutofillType; | 39 using autofill::AutofillType; |
| 40 using autofill::ServerFieldType; | 40 using autofill::ServerFieldType; |
| (...skipping 670 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 711 scoped_ptr<base::ListValue> components(new base::ListValue); | 711 scoped_ptr<base::ListValue> components(new base::ListValue); |
| 712 GetAddressComponents( | 712 GetAddressComponents( |
| 713 base::UTF16ToUTF8(profile.GetRawInfo(autofill::ADDRESS_HOME_COUNTRY)), | 713 base::UTF16ToUTF8(profile.GetRawInfo(autofill::ADDRESS_HOME_COUNTRY)), |
| 714 profile.language_code(), | 714 profile.language_code(), |
| 715 components.get(), | 715 components.get(), |
| 716 NULL); | 716 NULL); |
| 717 address->Set(kComponents, components.release()); | 717 address->Set(kComponents, components.release()); |
| 718 } | 718 } |
| 719 | 719 |
| 720 } // namespace options | 720 } // namespace options |
| OLD | NEW |