mirror of
https://github.com/signalapp/Signal-Android.git
synced 2025-12-24 21:15:48 +00:00
Show "declined" for declined voice and video calls instead of "missed".
Closes #14081 Fixes #14080
This commit is contained in:
@@ -83,18 +83,25 @@ object CallPreference {
|
||||
|
||||
@StringRes
|
||||
private fun getMissedCallString(isVideo: Boolean, callEvent: CallTable.Event): Int {
|
||||
return if (callEvent == CallTable.Event.MISSED_NOTIFICATION_PROFILE) {
|
||||
if (isVideo) {
|
||||
R.string.MessageRecord_missed_video_call_notification_profile
|
||||
} else {
|
||||
R.string.MessageRecord_missed_voice_call_notification_profile
|
||||
}
|
||||
} else {
|
||||
if (isVideo) {
|
||||
R.string.MessageRecord_missed_video_call
|
||||
} else {
|
||||
R.string.MessageRecord_missed_voice_call
|
||||
}
|
||||
return when (callEvent) {
|
||||
CallTable.Event.MISSED_NOTIFICATION_PROFILE ->
|
||||
if (isVideo) {
|
||||
R.string.MessageRecord_missed_video_call_notification_profile
|
||||
} else {
|
||||
R.string.MessageRecord_missed_voice_call_notification_profile
|
||||
}
|
||||
CallTable.Event.NOT_ACCEPTED ->
|
||||
if (isVideo) {
|
||||
R.string.MessageRecord_declined_video_call
|
||||
} else {
|
||||
R.string.MessageRecord_declined_voice_call
|
||||
}
|
||||
else ->
|
||||
if (isVideo) {
|
||||
R.string.MessageRecord_missed_video_call
|
||||
} else {
|
||||
R.string.MessageRecord_missed_voice_call
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -267,6 +267,8 @@ public class MmsMessageRecord extends MessageRecord {
|
||||
int message;
|
||||
if (call.getEvent() == CallTable.Event.MISSED_NOTIFICATION_PROFILE) {
|
||||
message = isVideoCall ? R.string.MessageRecord_missed_video_call_notification_profile : R.string.MessageRecord_missed_voice_call_notification_profile;
|
||||
} else if (call.getEvent() == CallTable.Event.NOT_ACCEPTED) {
|
||||
message = isVideoCall ? R.string.MessageRecord_declined_video_call : R.string.MessageRecord_declined_voice_call;
|
||||
} else {
|
||||
message = isVideoCall ? R.string.MessageRecord_missed_video_call : R.string.MessageRecord_missed_voice_call;
|
||||
}
|
||||
|
||||
@@ -1787,6 +1787,10 @@
|
||||
<string name="MessageRecord_missed_voice_call">Missed voice call</string>
|
||||
<!-- Update message shown when receiving an incoming 1:1 video call and not answered -->
|
||||
<string name="MessageRecord_missed_video_call">Missed video call</string>
|
||||
<!-- Update message shown when receiving an incoming 1:1 voice/audio call and not answered -->
|
||||
<string name="MessageRecord_declined_voice_call">Declined voice call</string>
|
||||
<!-- Update message shown when receiving an incoming 1:1 video call and not answered -->
|
||||
<string name="MessageRecord_declined_video_call">Declined video call</string>
|
||||
<!-- Update message shown when receiving an incoming voice call and declined due to notification profile -->
|
||||
<string name="MessageRecord_missed_voice_call_notification_profile">Missed voice call while notification profile on</string>
|
||||
<!-- Update message shown when receiving an incoming video call and declined due to notification profile -->
|
||||
|
||||
Reference in New Issue
Block a user