diff --git a/changelog.d/4144.bugfix b/changelog.d/4144.bugfix new file mode 100644 index 0000000000..1168245ecc --- /dev/null +++ b/changelog.d/4144.bugfix @@ -0,0 +1 @@ +Allowing users to hang up VOIP calls during the initialisation phase (avoids getting stuck in the call screen if something goes wrong) \ No newline at end of file diff --git a/vector/src/main/java/im/vector/app/features/call/CallControlsView.kt b/vector/src/main/java/im/vector/app/features/call/CallControlsView.kt index f0f75370e3..8d30c4d5c5 100644 --- a/vector/src/main/java/im/vector/app/features/call/CallControlsView.kt +++ b/vector/src/main/java/im/vector/app/features/call/CallControlsView.kt @@ -97,6 +97,8 @@ class CallControlsView @JvmOverloads constructor( views.ringingControlDecline.isVisible = true views.connectedControls.isVisible = false } + CallState.CreateOffer, + CallState.Idle, is CallState.Connected, is CallState.Dialing, is CallState.Answering -> { @@ -105,7 +107,7 @@ class CallControlsView @JvmOverloads constructor( views.videoToggleIcon.isVisible = state.isVideoCall views.moreIcon.isVisible = callState is CallState.Connected && callState.iceConnectionState == MxPeerConnectionState.CONNECTED } - else -> { + is CallState.Ended -> { views.ringingControls.isVisible = false views.connectedControls.isVisible = false }