From 1d8aef16692f800dbc0a384eb479d055e23a2665 Mon Sep 17 00:00:00 2001 From: Christian Ascheberg Date: Sat, 14 Nov 2015 13:30:33 +0100 Subject: [PATCH] Plural group join message Closes #4535 Fixes #4521 // FREEBIE --- res/values/strings.xml | 5 ++++- src/org/thoughtcrime/securesms/util/GroupUtil.java | 3 ++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/res/values/strings.xml b/res/values/strings.xml index d0f029742..05977fb66 100644 --- a/res/values/strings.xml +++ b/res/values/strings.xml @@ -690,7 +690,10 @@ The text entered was not a valid host - %1$s joined the group. + + %1$s joined the group. + %1$s joined the group. + Group updated. Group name is now \'%1$s\'. diff --git a/src/org/thoughtcrime/securesms/util/GroupUtil.java b/src/org/thoughtcrime/securesms/util/GroupUtil.java index c4075276e..fb7095ffb 100644 --- a/src/org/thoughtcrime/securesms/util/GroupUtil.java +++ b/src/org/thoughtcrime/securesms/util/GroupUtil.java @@ -74,7 +74,8 @@ public class GroupUtil { String title = groupContext.getName(); if (members != null) { - description.append(context.getString(R.string.GroupUtil_joined_the_group, members.toShortString())); + description.append(context.getResources().getQuantityString(R.plurals.GroupUtil_joined_the_group, + members.getRecipientsList().size(), members.toShortString())); } if (title != null && !title.trim().isEmpty()) {