mirror of
https://github.com/yattee/yattee.git
synced 2026-07-20 14:22:02 +00:00
Fix macOS opening player window instead of switching video in PiP
The PiP-active guard that skips expanding the player when opening a new video was compiled iOS-only, so on macOS a browser deep link always re-showed the hidden player window instead of playing the new video in the existing PiP window. Extend the guard in both openVideo overloads and the Handoff path to macOS.
This commit is contained in:
@@ -761,7 +761,7 @@ struct YatteeApp: App {
|
||||
// Always expand player after handoff (unless PiP is active)
|
||||
// We add a small delay to ensure ContentView has set up its .onChange observers
|
||||
// (during app launch via Handoff, the trigger can fire before the view is ready)
|
||||
#if os(iOS)
|
||||
#if os(iOS) || os(macOS)
|
||||
let isPiPActive = appEnvironment.playerService.state.pipState == .active
|
||||
#else
|
||||
let isPiPActive = false
|
||||
|
||||
Reference in New Issue
Block a user