Chromium Code Reviews| Index: components/autofill/core/browser/autofill_data_util.cc |
| diff --git a/components/autofill/core/browser/autofill_data_util.cc b/components/autofill/core/browser/autofill_data_util.cc |
| index e679d581cb9878f0a4f403bfdd71b743d1c95b3d..215b75829bc326ce644595ab7ed7dd90a4923488 100644 |
| --- a/components/autofill/core/browser/autofill_data_util.cc |
| +++ b/components/autofill/core/browser/autofill_data_util.cc |
| @@ -25,6 +25,8 @@ namespace { |
| // Mappings from Chrome card types to Payment Request API basic card payment |
| // spec types and icons. Note that "generic" is not in the spec. |
| // https://w3c.github.io/webpayments-methods-card/#method-id |
| +#if defined(OS_ANDROID) |
| +// On Android, use the PR-specific resource IDs. |
|
please use gerrit instead
2017/05/16 14:53:48
Do we plan to bring the goodies to Android eventua
Mathieu
2017/05/16 15:01:37
We can assess whether we want to keep vectors ther
|
| const PaymentRequestData kPaymentRequestData[]{ |
| {"americanExpressCC", "amex", IDR_AUTOFILL_PR_AMEX, IDS_AUTOFILL_CC_AMEX}, |
| {"dinersCC", "diners", IDR_AUTOFILL_PR_DINERS, IDS_AUTOFILL_CC_DINERS}, |
| @@ -40,6 +42,24 @@ const PaymentRequestData kPaymentRequestData[]{ |
| }; |
| const PaymentRequestData kGenericPaymentRequestData = { |
| "genericCC", "generic", IDR_AUTOFILL_PR_GENERIC, IDS_AUTOFILL_CC_GENERIC}; |
| +#else // !defined(OS_ANDROID) |
| +// On other platforms, use the Autofill resource IDs. |
| +const PaymentRequestData kPaymentRequestData[]{ |
| + {"americanExpressCC", "amex", IDR_AUTOFILL_CC_AMEX, IDS_AUTOFILL_CC_AMEX}, |
| + {"dinersCC", "diners", IDR_AUTOFILL_CC_DINERS, IDS_AUTOFILL_CC_DINERS}, |
| + {"discoverCC", "discover", IDR_AUTOFILL_CC_DISCOVER, |
| + IDS_AUTOFILL_CC_DISCOVER}, |
| + {"jcbCC", "jcb", IDR_AUTOFILL_CC_JCB, IDS_AUTOFILL_CC_JCB}, |
| + {"masterCardCC", "mastercard", IDR_AUTOFILL_CC_MASTERCARD, |
| + IDS_AUTOFILL_CC_MASTERCARD}, |
| + {"mirCC", "mir", IDR_AUTOFILL_CC_MIR, IDS_AUTOFILL_CC_MIR}, |
| + {"unionPayCC", "unionpay", IDR_AUTOFILL_CC_UNIONPAY, |
| + IDS_AUTOFILL_CC_UNION_PAY}, |
| + {"visaCC", "visa", IDR_AUTOFILL_CC_VISA, IDS_AUTOFILL_CC_VISA}, |
| +}; |
| +const PaymentRequestData kGenericPaymentRequestData = { |
| + "genericCC", "generic", IDR_AUTOFILL_CC_GENERIC, IDS_AUTOFILL_CC_GENERIC}; |
| +#endif |
| const char* const name_prefixes[] = { |
| "1lt", "1st", "2lt", "2nd", "3rd", "admiral", "capt", |