Im using SplitViewController and Swift-YouTube-Player to play youtube videos in app. It works perfectly on iPhone but it doesnt work on iPad.
On iPhone, when i trigger the player, it opens MPMoviewPLayer full screen and plays the video, but on iPad it plays at background I think, I can head the video's voice, but video does not appear.
I couldn't find a solution. Do you have any suggestion why player plays under the splitviewcontroller?
here is the trigger code
timer = NSTimer.scheduledTimerWithTimeInterval(4, target: self, selector: "alertVideo", userInfo: nil, repeats: false)
NSNotificationCenter.defaultCenter().addObserver(self, selector: "doneButton", name: UIWindowDidBecomeHiddenNotification, object:nil)
NSNotificationCenter.defaultCenter().addObserver(self, selector: "startVideo", name: UIWindowDidBecomeVisibleNotification , object:nil)
let a = MBProgressHUD.showHUDAddedTo(self.view, animated: true)
a.dimBackground = true
collectionView.deselectItemAtIndexPath(indexPath, animated: true)
let cell = collectionView.cellForItemAtIndexPath(indexPath)
let circleView : YouTubePlayerView? = (cell!.contentView.viewWithTag(10)) as? YouTubePlayerView
circleView?.play()
and this is the YouTubePLayer i use: https://github.com/gilesvangruisen/Swift-YouTube-Player