Added plural forms for download related strings (#6930)
Co-authored-by: Tobi <TobiGr@users.noreply.github.com>
This commit is contained in:
parent
023a2c1d9c
commit
43e91ae4ae
69 changed files with 27 additions and 194 deletions
|
|
@ -226,6 +226,16 @@ public final class Localization {
|
|||
shortCount(context, subscriberCount));
|
||||
}
|
||||
|
||||
public static String downloadCount(final Context context, final int downloadCount) {
|
||||
return getQuantity(context, R.plurals.download_finished_notification, 0,
|
||||
downloadCount, shortCount(context, downloadCount));
|
||||
}
|
||||
|
||||
public static String deletedDownloadCount(final Context context, final int deletedCount) {
|
||||
return getQuantity(context, R.plurals.deleted_downloads_toast, 0,
|
||||
deletedCount, shortCount(context, deletedCount));
|
||||
}
|
||||
|
||||
private static String getQuantity(final Context context, @PluralsRes final int pluralId,
|
||||
@StringRes final int zeroCaseStringId, final long count,
|
||||
final String formattedCount) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue