mirror of
https://github.com/element-hq/element-android
synced 2024-11-27 20:06:51 +03:00
Use string resource for generating ticker text.
This commit is contained in:
parent
2e4d30ef29
commit
6bbded1e65
2 changed files with 4 additions and 2 deletions
|
@ -344,9 +344,9 @@ class NotificationDrawerManager @Inject constructor(private val context: Context
|
||||||
}
|
}
|
||||||
|
|
||||||
val tickerText = if (roomEventGroupInfo.isDirect) {
|
val tickerText = if (roomEventGroupInfo.isDirect) {
|
||||||
String.format("%s: %s", events[0].senderName, events[0].description)
|
stringProvider.getString(R.string.notification_ticker_text_dm, events[0].senderName, events[0].description)
|
||||||
} else {
|
} else {
|
||||||
String.format("%s: %s %s", roomName, events[0].senderName, events[0].description)
|
stringProvider.getString(R.string.notification_ticker_text_group, roomName, events[0].senderName, events[0].description)
|
||||||
}
|
}
|
||||||
|
|
||||||
val notification = notificationUtils.buildMessagesListNotification(
|
val notification = notificationUtils.buildMessagesListNotification(
|
||||||
|
|
|
@ -1089,6 +1089,8 @@
|
||||||
<string name="notification_new_invitation">New Invitation</string>
|
<string name="notification_new_invitation">New Invitation</string>
|
||||||
<string name="notification_sender_me">Me</string>
|
<string name="notification_sender_me">Me</string>
|
||||||
<string name="notification_inline_reply_failed">** Failed to send - please open room</string>
|
<string name="notification_inline_reply_failed">** Failed to send - please open room</string>
|
||||||
|
<string name="notification_ticker_text_dm">%1$s: %2$s</string>
|
||||||
|
<string name="notification_ticker_text_group">%1$s: %2$s %3$s</string>
|
||||||
|
|
||||||
<!-- historical -->
|
<!-- historical -->
|
||||||
<string name="historical_placeholder">Search for historical</string>
|
<string name="historical_placeholder">Search for historical</string>
|
||||||
|
|
Loading…
Reference in a new issue