I ran into the same problem. James Chen's solution is correct, but I ended up doing something a little simpler, which also works - an overriding application: supportedInterfaceOrientationsForWindow in my delegate deletion and returning allButUpsideDown if my rootView controller was modally represented by MPMoviePlayerViewController. In truth, itβs hacky and may not suit all situations, but I managed to change all my view controllers:
- (NSUInteger) application:(UIApplication *)application supportedInterfaceOrientationsForWindow:(UIWindow *)window { return [rootViewController.modalViewController isKindOfClass:MPMoviePlayerViewController.class ] ? UIInterfaceOrientationMaskAll : UIInterfaceOrientationMaskAllButUpsideDown; }
source share