Minor fixes

This commit is contained in:
Arkadiusz Fal
2022-05-29 22:30:00 +02:00
parent f2e9bcaefe
commit d5558b2f85
4 changed files with 24 additions and 26 deletions

View File

@@ -24,7 +24,8 @@ final class PiPDelegate: NSObject, AVPictureInPictureControllerDelegate {
}
if player.avPlayerBackend.switchToMPVOnPipClose,
!player.currentItem.isNil {
!player.currentItem.isNil
{
DispatchQueue.main.async {
player.avPlayerBackend.switchToMPVOnPipClose = false
player.saveTime {
@@ -45,7 +46,7 @@ final class PiPDelegate: NSObject, AVPictureInPictureControllerDelegate {
if !player.currentItem.isNil {
player?.show()
}
DispatchQueue.main.asyncAfter(deadline: .now() + 0.3) {
completionHandler(true)
}