I once had a similar issue. It is not related to using segues. the issue is most probably with the constraints you are using. Set the top constraint of the YTPlayerView
with respect to the top layout guide instead of top of superview(which you may have currently done). I cannot specifically say a solution for this problem unless I know the constraints you have provided. Providing constraints with respect to the top of the super view causes this kind of issue when you are "Presenting" a view controller and the "Dismissing" it, which is similar to the action you are doing with IOS 9 back to the app option. Just try with the constraint as I mentioned and if it doesn't solve the problem, try to give some details about the constraints you are using.
EDIT
To be more specific, right now you must be setting the top constraint of the YTPlayerView
as a fixed distance (which is equal to the height of the navigation bar plus status bar, 64px I assume) to the top of the superview, which is the view of the ViewController. This need to be changed and the top constraint need to be set as 0px to the top layout guide. That should solve your problem.
EDIT 2
Since you are still having problem with it, try connecting the IBOutlet
of the top constraint to the ViewController and then in the view controller's viewDidAppear
method set it to zero.
Objective C:
topConstraint.constant = 0;
[self.view layoutSubviews];
Swift:
topConstraint.constant = 0
self.view.layoutSubviews()
Just to confirm, the superview of the YTPlayerView
is grey in colour right?