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

Unified Diff: chrome/browser/ui/views/payments/payment_sheet_view_controller.cc

Issue 2827293003: [Web Payments] Correct pluralization of "more items" (Closed)
Patch Set: Created 3 years, 8 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | components/payments_strings.grdp » ('j') | components/payments_strings.grdp » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/views/payments/payment_sheet_view_controller.cc
diff --git a/chrome/browser/ui/views/payments/payment_sheet_view_controller.cc b/chrome/browser/ui/views/payments/payment_sheet_view_controller.cc
index 5d390b8528ce48833f3195d11c0b0f4924ea30dc..2879be1be5c24e814bb64ef76f55fcf25c0507c3 100644
--- a/chrome/browser/ui/views/payments/payment_sheet_view_controller.cc
+++ b/chrome/browser/ui/views/payments/payment_sheet_view_controller.cc
@@ -439,9 +439,15 @@ PaymentSheetViewController::CreatePaymentSheetSummaryRow() {
int hidden_item_count = items.size() - kMaxNumberOfItemsShown;
if (hidden_item_count > 0) {
item_summaries_layout->StartRow(0, 0);
- std::unique_ptr<views::Label> label = base::MakeUnique<views::Label>(
- l10n_util::GetStringFUTF16(IDS_PAYMENT_REQUEST_ORDER_SUMMARY_MORE_ITEMS,
- base::IntToString16(hidden_item_count)));
+ base::string16 more_items_label =
please use gerrit instead 2017/04/20 15:05:27 Please see for an example of how this should be do
anthonyvd 2017/04/20 15:34:10 Ah, awesome! Done.
+ hidden_item_count == 1
+ ? l10n_util::GetStringUTF16(
+ IDS_PAYMENT_REQUEST_ORDER_SUMMARY_ONE_MORE_ITEM)
+ : l10n_util::GetStringFUTF16(
+ IDS_PAYMENT_REQUEST_ORDER_SUMMARY_MORE_ITEMS,
+ base::IntToString16(hidden_item_count));
+ std::unique_ptr<views::Label> label =
+ base::MakeUnique<views::Label>(more_items_label);
label->SetDisabledColor(label->GetNativeTheme()->GetSystemColor(
ui::NativeTheme::kColorId_LabelDisabledColor));
label->SetEnabled(false);
« no previous file with comments | « no previous file | components/payments_strings.grdp » ('j') | components/payments_strings.grdp » ('J')

Powered by Google App Engine
This is Rietveld 408576698