Releases the Mutex when stopping the feed.
This commit is contained in:
@@ -531,6 +531,7 @@ private fun RenderVideoPlayer(
|
|||||||
// if the user unmutes a video and it's not the current playing, switches to that one.
|
// if the user unmutes a video and it's not the current playing, switches to that one.
|
||||||
if (!mute && keepPlayingMutex != null && keepPlayingMutex != controller) {
|
if (!mute && keepPlayingMutex != null && keepPlayingMutex != controller) {
|
||||||
keepPlayingMutex?.stop()
|
keepPlayingMutex?.stop()
|
||||||
|
keepPlayingMutex?.release()
|
||||||
keepPlayingMutex = null
|
keepPlayingMutex = null
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -542,6 +543,7 @@ private fun RenderVideoPlayer(
|
|||||||
if (newKeepPlaying) {
|
if (newKeepPlaying) {
|
||||||
if (keepPlayingMutex != null && keepPlayingMutex != controller) {
|
if (keepPlayingMutex != null && keepPlayingMutex != controller) {
|
||||||
keepPlayingMutex?.stop()
|
keepPlayingMutex?.stop()
|
||||||
|
keepPlayingMutex?.release()
|
||||||
}
|
}
|
||||||
keepPlayingMutex = controller
|
keepPlayingMutex = controller
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
Reference in New Issue
Block a user