mirror of
https://github.com/element-hq/element-android
synced 2024-11-23 18:05:36 +03:00
Do not pause already paused voice broadcast
This commit is contained in:
parent
53db04c8cf
commit
85bc78bd72
2 changed files with 2 additions and 3 deletions
|
@ -234,7 +234,7 @@ class MessageComposerFragment : VectorBaseFragment<FragmentComposerBinding>(), A
|
|||
}
|
||||
// TODO remove this when there will be a recording indicator outside of the timeline
|
||||
// Pause voice broadcast if the timeline is not shown anymore
|
||||
it.isVoiceBroadcasting && !requireActivity().isChangingConfigurations -> timelineViewModel.handle(VoiceBroadcastAction.Recording.Pause)
|
||||
it.isRecordingVoiceBroadcast && !requireActivity().isChangingConfigurations -> timelineViewModel.handle(VoiceBroadcastAction.Recording.Pause)
|
||||
else -> {
|
||||
timelineViewModel.handle(VoiceBroadcastAction.Listening.Pause)
|
||||
messageComposerViewModel.handle(MessageComposerAction.OnEntersBackground(composer.text.toString()))
|
||||
|
|
|
@ -79,9 +79,8 @@ data class MessageComposerViewState(
|
|||
is VoiceMessageRecorderView.RecordingUiState.Recording -> true
|
||||
}
|
||||
|
||||
val isVoiceBroadcasting = when (voiceBroadcastState) {
|
||||
val isRecordingVoiceBroadcast = when (voiceBroadcastState) {
|
||||
VoiceBroadcastState.STARTED,
|
||||
VoiceBroadcastState.PAUSED,
|
||||
VoiceBroadcastState.RESUMED -> true
|
||||
else -> false
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue