mirror of
https://github.com/libre-tube/LibreTube.git
synced 2025-04-28 16:00:31 +05:30
different player error behavior
This commit is contained in:
parent
c54e99bf9a
commit
641a5fe9b9
@ -896,12 +896,12 @@ class PlayerFragment : BaseFragment() {
|
|||||||
* Catch player errors to prevent the app from stopping
|
* Catch player errors to prevent the app from stopping
|
||||||
*/
|
*/
|
||||||
override fun onPlayerError(error: PlaybackException) {
|
override fun onPlayerError(error: PlaybackException) {
|
||||||
Toast.makeText(
|
|
||||||
context,
|
|
||||||
error.localizedMessage,
|
|
||||||
Toast.LENGTH_LONG
|
|
||||||
).show()
|
|
||||||
super.onPlayerError(error)
|
super.onPlayerError(error)
|
||||||
|
try {
|
||||||
|
exoPlayer.play()
|
||||||
|
} catch (e: Exception) {
|
||||||
|
e.printStackTrace()
|
||||||
|
}
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user