Skip to content
Snippets Groups Projects
Commit f466ecb0 authored by Kazuki Takise's avatar Kazuki Takise Committed by Geoffrey Métais
Browse files

Support Picture-in-Picture on Chrome OS

enterPictureInPictureMode() must be called in onUserLeaveHint() to
support Picture-in-Picture in a multi-window environment such as
Chrome OS.

The current implemententation (calling the API in onPause()) causes
the following issues on Chrome OS:

- VLC enters PiP without being occluded, but just with another
  window activated. In a multi-window environment, we can't assume
  onPause() means the window gets hidden. As only one window can
  be resumed at the same time, it's possible that a window is
  fully visible, but paused.
- When some ChromeOS-specific system UI gets shown (e.g. Alt-Tab
  window cycler, Overview Mode), VLC enters PiP unexpectedly.

This patch moves switchToPopup() from onPause() to onUserLeaveHint()
to prevent those issues.
parent 95c9aa0a
No related branches found
No related tags found
1 merge request!380Support Picture-in-Picture on Chrome OS
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment