From 933a8fdcd5ec7f7fd1d0768e7c9b43351cfa4e20 Mon Sep 17 00:00:00 2001 From: cketti Date: Tue, 24 Jul 2012 00:39:58 +0200 Subject: [PATCH] Made actionbar_selected a format string --- res/values/strings.xml | 2 +- src/com/fsck/k9/activity/MessageList.java | 6 ++++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/res/values/strings.xml b/res/values/strings.xml index 12639c88d..76f7020d5 100644 --- a/res/values/strings.xml +++ b/res/values/strings.xml @@ -99,7 +99,7 @@ http://k9mail.googlecode.com/ \u0020(Next poll @ %s) \u0020(Syncing disabled) - selected + %d selected Next Previous diff --git a/src/com/fsck/k9/activity/MessageList.java b/src/com/fsck/k9/activity/MessageList.java index a8a27bc71..690d0e8a5 100644 --- a/src/com/fsck/k9/activity/MessageList.java +++ b/src/com/fsck/k9/activity/MessageList.java @@ -696,7 +696,9 @@ public class MessageList extends K9ListActivity implements mSelectedCount = getSelectionFromCheckboxes().size(); if (mSelectedCount > 0) { mActionMode = MessageList.this.startActionMode(mActionModeCallback); - mActionMode.setTitle(mSelectedCount + " " + getString(R.string.actionbar_selected)); + mActionMode.setTitle(String.format( + getString(R.string.actionbar_selected), + mSelectedCount)); } } @@ -2380,7 +2382,7 @@ public class MessageList extends K9ListActivity implements mSelectedCount += 1; } mAdapter.notifyDataSetChanged(); - mActionMode.setTitle(mSelectedCount+" "+getString(R.string.actionbar_selected)); + mActionMode.setTitle(String.format(getString(R.string.actionbar_selected), mSelectedCount)); if (mQueryString != null) { // we might have to disable some options