Voice broadcast connection error handling while recording (#7282)

This commit is contained in:
Yoan Pintas
2023-01-18 16:27:13 +00:00
committed by GitHub
parent 152fc60aa1
commit d34cebc6be
13 changed files with 152 additions and 49 deletions
@@ -56,6 +56,8 @@ class VoiceBroadcastRecorderViewModel: VoiceBroadcastRecorderViewModelType, Voic
pause()
case .resume:
resume()
case .pauseOnError:
pauseOnError()
}
}
@@ -80,6 +82,10 @@ class VoiceBroadcastRecorderViewModel: VoiceBroadcastRecorderViewModelType, Voic
voiceBroadcastRecorderService.resumeRecordingVoiceBroadcast()
}
private func pauseOnError() {
voiceBroadcastRecorderService.pauseOnErrorRecordingVoiceBroadcast()
}
private func updateRemainingTime(_ remainingTime: UInt) {
state.currentRecordingState = VoiceBroadcastRecorderViewModel.currentRecordingState(from: remainingTime)
}