Merge pull request #6171 from Bnyro/master

fix: crash when entering audio mode via pip
This commit is contained in:
Bnyro 2024-06-21 16:57:22 +02:00 committed by GitHub
commit 007dfbaf82
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -688,9 +688,11 @@ class PlayerFragment : Fragment(), OnlinePlayerOptions {
@SuppressLint("SourceLockedOrientationActivity")
fun unsetFullscreen() {
if (activity == null || _binding == null) return
viewModel.isFullscreen.value = false
if (!PlayerHelper.autoFullscreenEnabled && activity != null) {
if (!PlayerHelper.autoFullscreenEnabled) {
mainActivity.requestedOrientation = mainActivity.screenOrientationPref
}