Skip to content

Commit

Permalink
fix quality switching in the internal player
Browse files Browse the repository at this point in the history
  • Loading branch information
jmir1 committed Jul 13, 2021
1 parent e14a5a3 commit 38b2e42
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -285,9 +285,9 @@ class PlayerActivity : AppCompatActivity() {
val nextQuality = if (currentQuality == videos.lastIndex) 0 else currentQuality + 1
baseContext.toast(videos[nextQuality].quality, Toast.LENGTH_SHORT)
uri = if (isLocal) {
videos.first().uri!!.toString()
videos[nextQuality].uri!!.toString()
} else {
videos.first().videoUrl!!
videos[nextQuality].videoUrl!!
}
currentQuality = nextQuality
mediaItem = MediaItem.Builder()
Expand Down

0 comments on commit 38b2e42

Please sign in to comment.