fix: restore fullscreen after PiP

This commit is contained in:
Bnyro 2023-11-05 13:11:24 +01:00
parent c6350d36ed
commit a593da17c1
2 changed files with 4 additions and 10 deletions

View File

@ -1492,11 +1492,6 @@ class PlayerFragment : Fragment(), OnlinePlayerOptions {
binding.player.hideController()
binding.player.useController = false
if (viewModel.isMiniPlayerVisible.value == true) {
binding.playerMotionLayout.transitionToStart()
viewModel.isMiniPlayerVisible.value = false
}
updateCurrentSubtitle(null)
openOrCloseFullscreenDialog(true)
@ -1510,11 +1505,10 @@ class PlayerFragment : Fragment(), OnlinePlayerOptions {
updateCurrentSubtitle(currentSubtitle)
binding.optionsLL.post {
binding.optionsLL.requestLayout()
// unset fullscreen if it's not been enabled before the start of PiP
if (viewModel.isFullscreen.value != true) {
openOrCloseFullscreenDialog(false)
}
openOrCloseFullscreenDialog(false)
}
}

View File

@ -181,7 +181,7 @@ class OnlinePlayerView(
super.hideController()
if (playerViewModel?.isFullscreen?.value == true) {
toggleSystemBars(true)
toggleSystemBars(false)
}
updateTopBarMargin()
}