Fixed video not being visible when playing recording unless it is paused/resumed
This commit is contained in:
parent
2e1b6baa6c
commit
2e5603cb41
3 changed files with 4 additions and 4 deletions
|
@ -119,10 +119,10 @@ class RecordingData(val path: String, private val recordingListener: RecordingLi
|
|||
player.open(path)
|
||||
player.seek(0)
|
||||
}
|
||||
recordingListener.onPlayingStarted(isVideoAvailable())
|
||||
|
||||
player.start()
|
||||
isPlaying.value = true
|
||||
recordingListener.onPlayingStarted(isVideoAvailable())
|
||||
|
||||
scope.launch {
|
||||
withContext(Dispatchers.IO) {
|
||||
|
|
|
@ -114,7 +114,7 @@ class RecordingsFragment : MasterFragment<RecordingsFragmentBinding, RecordingsL
|
|||
|
||||
override fun onResume() {
|
||||
if (this::viewModel.isInitialized) {
|
||||
viewModel.udpdateRecordingsList()
|
||||
viewModel.updateRecordingsList()
|
||||
} else {
|
||||
Log.e("[Recordings] Fragment resuming but viewModel lateinit property isn't initialized!")
|
||||
}
|
||||
|
|
|
@ -85,10 +85,10 @@ class RecordingsViewModel : ViewModel() {
|
|||
FileUtils.deleteFile(recording.path)
|
||||
}
|
||||
|
||||
udpdateRecordingsList()
|
||||
updateRecordingsList()
|
||||
}
|
||||
|
||||
fun udpdateRecordingsList() {
|
||||
fun updateRecordingsList() {
|
||||
recordingsList.value.orEmpty().forEach(RecordingData::destroy)
|
||||
val list = arrayListOf<RecordingData>()
|
||||
|
||||
|
|
Loading…
Reference in a new issue