Pause before dismissing player on tvOS

This commit is contained in:
Arkadiusz Fal 2022-01-07 19:48:03 +01:00
parent d1ed896166
commit 5b12dbcb1e

View File

@ -127,6 +127,9 @@ extension PlayerViewController: AVPlayerViewControllerDelegate {
}
func playerViewControllerWillBeginDismissalTransition(_: AVPlayerViewController) {
if Defaults[.pauseOnHidingPlayer] {
playerModel.pause()
}
dismiss(animated: false)
}