Merge pull request #5512 from Bnyro/master

refactor: simplify initalization of MutableLiveData in PlayerViewModel.kt
This commit is contained in:
Bnyro 2024-01-18 17:27:14 +01:00 committed by GitHub
commit e8b911c6fa
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -8,12 +8,8 @@ import com.github.libretube.api.obj.ChapterSegment
class PlayerViewModel : ViewModel() {
var player: ExoPlayer? = null
val isMiniPlayerVisible = MutableLiveData<Boolean>().apply {
value = false
}
val isFullscreen = MutableLiveData<Boolean>().apply {
value = false
}
val isMiniPlayerVisible = MutableLiveData(false)
val isFullscreen = MutableLiveData(false)
var maxSheetHeightPx = 0