1
0
mirror of https://github.com/TeamNewPipe/NewPipe synced 2024-06-26 07:03:20 +00:00

Merge pull request #4939 from Atemu/dont-exit-fullscreen-on-rotation

VideoDetailFragment: Don't exit fullscreen on rotation in tablet UI
This commit is contained in:
Tobias Groza 2021-01-14 16:25:51 +01:00 committed by GitHub
commit 8fd48a88be
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -277,7 +277,9 @@ public final class VideoDetailFragment
// If the video is playing but orientation changed
// let's make the video in fullscreen again
checkLandscape();
} else if (player.isFullscreen() && !player.isVerticalVideo()) {
} else if (player.isFullscreen() && !player.isVerticalVideo()
// Tablet UI has orientation-independent fullscreen
&& !DeviceUtils.isTablet(activity)) {
// Device is in portrait orientation after rotation but UI is in fullscreen.
// Return back to non-fullscreen state
player.toggleFullscreen();