mirror of
https://gitlab.com/ultrasonic/ultrasonic.git
synced 2025-06-04 01:31:03 +03:00
Fix crashes with Jukebox
This commit is contained in:
parent
97cd7db177
commit
1c5d7fe214
@ -25,7 +25,7 @@ swipeRefresh = "1.1.0"
|
||||
retrofit = "2.9.0"
|
||||
jackson = "2.14.2"
|
||||
okhttp = "4.10.0"
|
||||
koin = "3.3.3"
|
||||
koin = "3.3.2"
|
||||
picasso = "2.8"
|
||||
|
||||
junit4 = "4.13.2"
|
||||
|
@ -299,7 +299,9 @@ class PlayerFragment :
|
||||
}
|
||||
|
||||
playButton.setOnClickListener {
|
||||
networkAndStorageChecker.warnIfNetworkOrStorageUnavailable()
|
||||
if (!mediaPlayerController.isJukeboxEnabled)
|
||||
networkAndStorageChecker.warnIfNetworkOrStorageUnavailable()
|
||||
|
||||
launch(CommunicationError.getHandler(context)) {
|
||||
mediaPlayerController.play()
|
||||
onCurrentChanged()
|
||||
|
@ -273,6 +273,10 @@ class JukeboxMediaPlayer : JukeboxUnimplementedFunctions(), Player {
|
||||
seekTo((jukeboxStatus?.positionSeconds ?: 0) + SEEK_INCREMENT_SECONDS)
|
||||
}
|
||||
|
||||
override fun isCurrentMediaItemSeekable() = true
|
||||
|
||||
override fun isCurrentMediaItemLive() = false
|
||||
|
||||
override fun prepare() {}
|
||||
|
||||
override fun isPlaying(): Boolean {
|
||||
|
@ -189,18 +189,10 @@ abstract class JukeboxUnimplementedFunctions : Service(), Player {
|
||||
TODO("Not yet implemented")
|
||||
}
|
||||
|
||||
override fun isCurrentMediaItemLive(): Boolean {
|
||||
TODO("Not yet implemented")
|
||||
}
|
||||
|
||||
override fun isCurrentWindowSeekable(): Boolean {
|
||||
TODO("Not yet implemented")
|
||||
}
|
||||
|
||||
override fun isCurrentMediaItemSeekable(): Boolean {
|
||||
TODO("Not yet implemented")
|
||||
}
|
||||
|
||||
override fun clearVideoSurface() {
|
||||
TODO("Not yet implemented")
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user