X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=src%2Fchrome%2Fbrowser%2Fui%2Fautofill%2Fautofill_dialog_i18n_input.cc;h=5dc33e3ca7fcaa7ac0e893d1fb92cb964ab64a4e;hb=004985e17e624662a4c85c76a7654039dc83f028;hp=c079e3d9c5cb82b28f4f32eeede7e9bb599d704c;hpb=2f108dbacb161091e42a3479f4e171339b7e7623;p=platform%2Fframework%2Fweb%2Fcrosswalk.git diff --git a/src/chrome/browser/ui/autofill/autofill_dialog_i18n_input.cc b/src/chrome/browser/ui/autofill/autofill_dialog_i18n_input.cc index c079e3d..5dc33e3 100644 --- a/src/chrome/browser/ui/autofill/autofill_dialog_i18n_input.cc +++ b/src/chrome/browser/ui/autofill/autofill_dialog_i18n_input.cc @@ -38,12 +38,12 @@ DetailInput::Length LengthFromHint(AddressUiComponent::LengthHint hint) { void BuildAddressInputs(common::AddressType address_type, const std::string& country_code, - DetailInputs* inputs) { - // TODO(rouslan): Store the language code for the autofill profile. - // http://crbug.com/354955 + DetailInputs* inputs, + std::string* language_code) { std::vector components( ::i18n::addressinput::BuildComponents( - country_code, g_browser_process->GetApplicationLocale(), NULL)); + country_code, g_browser_process->GetApplicationLocale(), + language_code)); const bool billing = address_type == common::ADDRESS_TYPE_BILLING; @@ -59,18 +59,6 @@ void BuildAddressInputs(common::AddressType address_type, base::string16 placeholder = l10n_util::GetStringUTF16(component.name_id); DetailInput input = { length, server_type, placeholder }; inputs->push_back(input); - -#if defined(OS_MACOSX) || defined(OS_ANDROID) - if (component.field == ::i18n::addressinput::STREET_ADDRESS && - component.length_hint == AddressUiComponent::HINT_LONG) { - // TODO(dbeam): support more than 2 address lines. http://crbug.com/324889 - ServerFieldType server_type = - billing ? ADDRESS_BILLING_LINE2 : ADDRESS_HOME_LINE2; - base::string16 placeholder = l10n_util::GetStringUTF16(component.name_id); - DetailInput input = { length, server_type, placeholder }; - inputs->push_back(input); - } -#endif } ServerFieldType server_type = @@ -147,14 +135,9 @@ ServerFieldType TypeForField(AddressField address_field, return billing ? ADDRESS_BILLING_ZIP : ADDRESS_HOME_ZIP; case ::i18n::addressinput::SORTING_CODE: return billing ? ADDRESS_BILLING_SORTING_CODE : ADDRESS_HOME_SORTING_CODE; -#if defined(OS_MACOSX) || defined(OS_ANDROID) - case ::i18n::addressinput::STREET_ADDRESS: - return billing ? ADDRESS_BILLING_LINE1 : ADDRESS_HOME_LINE1; -#else case ::i18n::addressinput::STREET_ADDRESS: return billing ? ADDRESS_BILLING_STREET_ADDRESS : ADDRESS_HOME_STREET_ADDRESS; -#endif case ::i18n::addressinput::RECIPIENT: return billing ? NAME_BILLING_FULL : NAME_FULL; case ::i18n::addressinput::ORGANIZATION: