summaryrefslogtreecommitdiffstats
path: root/chrome/browser/ui/autofill
diff options
context:
space:
mode:
Diffstat (limited to 'chrome/browser/ui/autofill')
-rw-r--r--chrome/browser/ui/autofill/autofill_dialog_controller_browsertest.cc5
-rw-r--r--chrome/browser/ui/autofill/autofill_dialog_controller_impl.cc2
-rw-r--r--chrome/browser/ui/autofill/autofill_dialog_controller_unittest.cc10
-rw-r--r--chrome/browser/ui/autofill/data_model_wrapper.cc2
4 files changed, 9 insertions, 10 deletions
diff --git a/chrome/browser/ui/autofill/autofill_dialog_controller_browsertest.cc b/chrome/browser/ui/autofill/autofill_dialog_controller_browsertest.cc
index 6d1f30d..6cc9689 100644
--- a/chrome/browser/ui/autofill/autofill_dialog_controller_browsertest.cc
+++ b/chrome/browser/ui/autofill/autofill_dialog_controller_browsertest.cc
@@ -899,9 +899,8 @@ IN_PROC_BROWSER_TEST_F(AutofillDialogControllerTest,
ASSERT_TRUE(controller);
const CreditCard& credit_card = test::GetVerifiedCreditCard();
- ASSERT_TRUE(
- credit_card.GetRawInfo(CREDIT_CARD_NAME).find(ASCIIToUTF16("zebra")) ==
- base::string16::npos);
+ ASSERT_TRUE(credit_card.GetRawInfo(CREDIT_CARD_NAME_FULL)
+ .find(ASCIIToUTF16("zebra")) == base::string16::npos);
AddCreditcardToProfile(controller->profile(), credit_card);
AddAutofillProfileToProfile(controller->profile(),
test::GetVerifiedProfile());
diff --git a/chrome/browser/ui/autofill/autofill_dialog_controller_impl.cc b/chrome/browser/ui/autofill/autofill_dialog_controller_impl.cc
index ccfe477..5937dc3 100644
--- a/chrome/browser/ui/autofill/autofill_dialog_controller_impl.cc
+++ b/chrome/browser/ui/autofill/autofill_dialog_controller_impl.cc
@@ -1685,7 +1685,7 @@ void AutofillDialogControllerImpl::FillOutputForSectionWithComparator(
FillFormGroupFromOutputs(output, &card);
// The card holder name comes from the billing address section.
- card.SetRawInfo(CREDIT_CARD_NAME,
+ card.SetRawInfo(CREDIT_CARD_NAME_FULL,
GetValueFromSection(SECTION_BILLING, NAME_BILLING_FULL));
if (ShouldSaveDetailsLocally()) {
diff --git a/chrome/browser/ui/autofill/autofill_dialog_controller_unittest.cc b/chrome/browser/ui/autofill/autofill_dialog_controller_unittest.cc
index d10b628..ecee41e 100644
--- a/chrome/browser/ui/autofill/autofill_dialog_controller_unittest.cc
+++ b/chrome/browser/ui/autofill/autofill_dialog_controller_unittest.cc
@@ -483,7 +483,7 @@ class AutofillDialogControllerTest : public ChromeRenderViewHostTestHarness {
EXPECT_FALSE(shipping_country.empty());
EXPECT_EQ(billing_country, shipping_country);
- EXPECT_EQ(CREDIT_CARD_NAME,
+ EXPECT_EQ(CREDIT_CARD_NAME_FULL,
form_structure()->field(1)->Type().GetStorableType());
base::string16 cc_name = form_structure()->field(1)->value;
EXPECT_EQ(NAME_FULL, form_structure()->field(6)->Type().GetStorableType());
@@ -984,7 +984,7 @@ TEST_F(AutofillDialogControllerTest, AutofillCreditCards) {
// Empty cards are ignored.
CreditCard empty_card(base::GenerateGUID(), kSettingsOrigin);
- empty_card.SetRawInfo(CREDIT_CARD_NAME, ASCIIToUTF16("John Doe"));
+ empty_card.SetRawInfo(CREDIT_CARD_NAME_FULL, ASCIIToUTF16("John Doe"));
controller()->GetTestingManager()->AddTestingCreditCard(&empty_card);
EXPECT_FALSE(controller()->MenuModelForSection(SECTION_CC));
@@ -1030,7 +1030,7 @@ TEST_F(AutofillDialogControllerTest, DontUseBillingAsShipping) {
EXPECT_FALSE(shipping_state.empty());
EXPECT_NE(billing_state, shipping_state);
- EXPECT_EQ(CREDIT_CARD_NAME,
+ EXPECT_EQ(CREDIT_CARD_NAME_FULL,
form_structure()->field(1)->Type().GetStorableType());
base::string16 cc_name = form_structure()->field(1)->value;
EXPECT_EQ(NAME_FULL, form_structure()->field(6)->Type().GetStorableType());
@@ -1480,7 +1480,7 @@ TEST_F(AutofillDialogControllerTest, SaveCreditCardIncludesName_NoBilling) {
TestPersonalDataManager* test_pdm = controller()->GetTestingManager();
const CreditCard& imported_card = test_pdm->imported_credit_card();
EXPECT_EQ(test_profile.GetInfo(AutofillType(NAME_FULL), "en-US"),
- imported_card.GetRawInfo(CREDIT_CARD_NAME));
+ imported_card.GetRawInfo(CREDIT_CARD_NAME_FULL));
}
TEST_F(AutofillDialogControllerTest, SaveCreditCardIncludesName_WithBilling) {
@@ -1499,7 +1499,7 @@ TEST_F(AutofillDialogControllerTest, SaveCreditCardIncludesName_WithBilling) {
const CreditCard& imported_card = test_pdm->imported_credit_card();
EXPECT_EQ(test_profile.GetInfo(AutofillType(NAME_FULL), "en-US"),
- imported_card.GetRawInfo(CREDIT_CARD_NAME));
+ imported_card.GetRawInfo(CREDIT_CARD_NAME_FULL));
controller()->ViewClosed();
}
diff --git a/chrome/browser/ui/autofill/data_model_wrapper.cc b/chrome/browser/ui/autofill/data_model_wrapper.cc
index 6a71ee3..b00e5da 100644
--- a/chrome/browser/ui/autofill/data_model_wrapper.cc
+++ b/chrome/browser/ui/autofill/data_model_wrapper.cc
@@ -110,7 +110,7 @@ base::string16 AutofillProfileWrapper::GetInfo(const AutofillType& type) const {
// but the AutofillProfile class doesn't know how to fill credit card
// fields. So, request for the corresponding profile type instead.
AutofillType effective_type = type;
- if (type.GetStorableType() == CREDIT_CARD_NAME)
+ if (type.GetStorableType() == CREDIT_CARD_NAME_FULL)
effective_type = AutofillType(NAME_BILLING_FULL);
const std::string& app_locale = g_browser_process->GetApplicationLocale();