Video calls are shown as a voice ones in the timeline (Fixes #1676)
This commit is contained in:
parent
5063188b25
commit
139cd051ab
|
@ -8,7 +8,7 @@ Improvements 🙌:
|
||||||
-
|
-
|
||||||
|
|
||||||
Bugfix 🐛:
|
Bugfix 🐛:
|
||||||
-
|
- Video calls are shown as a voice ones in the timeline (#1676)
|
||||||
|
|
||||||
Translations 🗣:
|
Translations 🗣:
|
||||||
-
|
-
|
||||||
|
|
|
@ -59,5 +59,5 @@ data class CallInviteContent(
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
fun isVideo(): Boolean = offer?.sdp?.contains(Offer.SDP_VIDEO) == true
|
fun isVideo() = offer?.sdp?.contains(Offer.SDP_VIDEO) == true
|
||||||
}
|
}
|
||||||
|
|
|
@ -286,7 +286,7 @@ class NoticeEventFormatter @Inject constructor(private val activeSessionDataSour
|
||||||
return when (type) {
|
return when (type) {
|
||||||
EventType.CALL_INVITE -> {
|
EventType.CALL_INVITE -> {
|
||||||
val content = event.getClearContent().toModel<CallInviteContent>() ?: return null
|
val content = event.getClearContent().toModel<CallInviteContent>() ?: return null
|
||||||
val isVideoCall = content.offer?.sdp == CallInviteContent.Offer.SDP_VIDEO
|
val isVideoCall = content.isVideo()
|
||||||
return if (isVideoCall) {
|
return if (isVideoCall) {
|
||||||
if (event.isSentByCurrentUser()) {
|
if (event.isSentByCurrentUser()) {
|
||||||
sp.getString(R.string.notice_placed_video_call_by_you)
|
sp.getString(R.string.notice_placed_video_call_by_you)
|
||||||
|
|
Loading…
Reference in New Issue