SvenTiigi / YouTubePlayerKit

A Swift Package to easily play YouTube videos 📺
https://sventiigi.github.io/YouTubePlayerKit/
MIT License
723 stars 64 forks source link

Is there any way to detect fullscreen events ? #61

Closed rijink7 closed 1 year ago

rijink7 commented 1 year ago

Is there any way to detect fullscreen events?

SvenTiigi commented 1 year ago

Although YouTubePlayerKit doesn't provide any kind of fullscreen detection API I think you should easily detect the fullscreen mode by subscribing to the UIWindow.didBecomeHiddenNotification and UIWindow.didBecomeVisibleNotification using the NotificationCenter.