[video_player] Add Picture-in-Picture support for iOS#11105
Draft
akaboshinit wants to merge 2 commits intoflutter:mainfrom
Draft
[video_player] Add Picture-in-Picture support for iOS#11105akaboshinit wants to merge 2 commits intoflutter:mainfrom
akaboshinit wants to merge 2 commits intoflutter:mainfrom
Conversation
|
Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA). View this failed invocation of the CLA check for more information. For the most up to date status, view the checks section at the bottom of the pull request. |
22c5159 to
73d6bea
Compare
Adds PiP support across three packages: ## video_player_platform_interface (6.6.0 → 6.7.0) - Add enablePictureInPicture, disablePictureInPicture, startPictureInPicture, stopPictureInPicture, isPictureInPictureSupported, isPictureInPictureActive - Add pipStarted, pipStopped, pipRestoreUserInterface event types ## video_player_avfoundation (2.9.3 → 2.10.0) - Integrate AVPictureInPictureController with AVPlayerLayer - Support both texture-based and platform view players - Implement PiP delegate callbacks (start/stop/restore UI) - macOS returns stub implementations (PiP not supported) - Requires iOS 14.2+ ## video_player (2.11.0 → 2.12.0) - Add isPictureInPictureActive field to VideoPlayerValue - Add PiP methods to VideoPlayerController - Handle PiP events in the event listener Fixes flutter/flutter#60048
73d6bea to
3fc8655
Compare
11 tasks
…InPicture APIs The native iOS implementation already sets up PiP automatically during player initialization, making enablePictureInPicture a no-op check. disablePictureInPicture's cleanup is already handled by dispose. Removing these simplifies the API surface without losing functionality.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Adds Picture-in-Picture (PiP) support for iOS to the video_player plugin across three packages.
Fixes flutter/flutter#60048
video_player_platform_interface (6.6.0 → 6.7.0)
enablePictureInPicture(),disablePictureInPicture(),startPictureInPicture(),stopPictureInPicture(),isPictureInPictureSupported(), andisPictureInPictureActive()methodspipStarted,pipStopped,pipRestoreUserInterfaceevent types toVideoEventTypevideo_player_avfoundation (2.9.3 → 2.10.0)
AVPictureInPictureControllerwithAVPlayerLayervideo_player (2.11.0 → 2.12.0)
isPictureInPictureActivefield toVideoPlayerValueVideoPlayerControllerpipStarted,pipStopped,pipRestoreUserInterfaceeventsExample app
Test plan
VideoPlayerController(video_player)VideoPlayerValue.isPictureInPictureActivestate updates (video_player)StateError(video_player)Pre-Review Checklist
[video_player]pubspec.yamlwith an appropriate new version according to the [pub versioning philosophy], or I have commented below to indicate which [version change exemption] this PR falls under1.CHANGELOG.mdto add a description of the change, [following repository CHANGELOG style], or I have commented below to indicate which [CHANGELOG exemption] this PR falls under1.///).Footnotes
See the docs on contributing for details. ↩ ↩2 ↩3