Repository navigation
In-place AVPlayerItem handover across native loads while PiP is active - #159
Merged
Merged
Conversation
…le PiP is active A system PiP window closes when its source layer's player drops its item; the load teardown nulled it for the whole load gap. load() now arms shouldHandOverItemInPlace, stopInternal defers the item detach (keepCurrentItem), and the loopback host.load callsite swaps in place (inPlaceSwap), keeping the old item playing until replaceCurrentItem hands over the ready master. Fixes next-episode transitions closing the tvOS PiP window. Closes #158 Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01NAPCg4tCDdSqkK6tPkNptw
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.
Fixes #158. A system PiP window closes the moment its source layer's player drops its item; the load teardown nulled it for the whole load gap (probe, demuxer, fresh loopback session). The #93 in-PiP recovery reload already established the failure mode and the
inPlaceSwapmechanism. This wires it into the regular load path:load()armsshouldHandOverItemInPlace(pipActive:priorBackendWasNative:),stopInternaldefers the item detach behind the newkeepCurrentItemparameter, and the loopbackhost.loadcallsite consumes the armed handover asinPlaceSwap(consume-and-reset, so audio-switch and recovery reloads keep their contracts). The old item keeps playing untilreplaceCurrentItemswaps in the ready master with transport intent latched. Covered byPiPItemHandoverTests; full suite 782 green, tvOS sim build clean.🤖 Generated with Claude Code
https://claude.ai/code/session_01NAPCg4tCDdSqkK6tPkNptw