Try to patch #78

Issue appears when app switches layout from tab to sidebar navigation
This commit is contained in:
Arkadiusz Fal 2022-04-03 15:26:33 +02:00
parent 9fc4638298
commit 512899235e

View File

@ -227,6 +227,19 @@ struct VideoPlayerView: View {
PlayerControls(player: player)
}
#if os(iOS)
.onAppear {
// ugly patch for #78
guard player.activeBackend == .mpv else {
return
}
player.activeBackend = .appleAVPlayer
DispatchQueue.main.asyncAfter(deadline: .now() + 0.1) {
player.activeBackend = .mpv
}
}
#endif
}
var fullScreenLayout: Bool {