Change group call notification title and body

This commit is contained in:
ismailgulek
2021-04-20 16:04:58 +03:00
parent ba74899e92
commit 983995b282
2 changed files with 3 additions and 2 deletions

View File

@@ -124,7 +124,7 @@
"VIDEO_CONF_NAMED_FROM_USER" = "Video group call from %@: '%@'";
/* A user added a Jitsi call to a room */
"GROUP_CALL_STARTED_IN_ROOM" = "%@ added a group call to %@";
"GROUP_CALL_STARTED" = "Group call started";
/* Group call from user, CallKit caller name */
"GROUP_CALL_FROM_USER" = "%@ (Group call)";

View File

@@ -377,7 +377,8 @@ class NotificationService: UNNotificationServiceExtension {
if event.type == kWidgetMatrixEventTypeString || event.type == kWidgetModularEventTypeString {
if let content = event.content, let type = content["type"] as? String {
if type == kWidgetTypeJitsiV1 || type == kWidgetTypeJitsiV2 {
notificationBody = NSString.localizedUserNotificationString(forKey: "GROUP_CALL_STARTED_IN_ROOM", arguments: [eventSenderName as Any, roomDisplayName as Any])
notificationBody = NSString.localizedUserNotificationString(forKey: "GROUP_CALL_STARTED", arguments: nil)
notificationTitle = roomDisplayName
// call notifications should stand out from normal messages, so we don't stack them
threadIdentifier = nil