Skip to content

Commit

Permalink
fix: check multi window mode when host pause
Browse files Browse the repository at this point in the history
- some OS version call onPause on multi-window mode
  • Loading branch information
YangJonghun committed Jan 23, 2024
1 parent d10f624 commit 1b3a0b2
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -383,7 +383,9 @@ public void onHostPause() {
enterPictureInPictureMode();
return;
}
if (playInBackground || isInPictureInPicture) {
Activity activity = themedReactContext.getCurrentActivity();
boolean isInMultiWindowMode = Util.SDK_INT >= 24 && (activity.isInMultiWindowMode());
if (playInBackground || isInPictureInPicture || isInMultiWindowMode) {
return;
}
setPlayWhenReady(false);
Expand Down

0 comments on commit 1b3a0b2

Please sign in to comment.