Я справился с этой проблемой, используя NSNotification, например, в методе viewDidLoad
[[NSNotificationCenter defaultCenter] addObserver:self
selector:@selector(moviePlayerDidExitFullScreen)
name:@"UIMoviePlayerControllerDidExitFullscreenNotification"
object:nil];
, и этот метод будет вызываться по окончании видео, и вы сможете внести необходимые изменения
- (void)moviePlayerDidExitFullScreen
{
UIInterfaceOrientation orientation = [UIApplication sharedApplication].statusBarOrientation;
if (orientation == UIInterfaceOrientationLandscapeLeft || orientation == UIInterfaceOrientationLandscapeRight || orientation == UIInterfaceOrientationPortraitUpsideDown)
{
[[UIDevice currentDevice] setOrientation:UIInterfaceOrientationPortrait];
}
}
Надеюсь, что это поможет