I have a UITabBar with a lot of view controllers and navigation controller. I am trying to support both orientations but only portrait works. I know that I have to override this method in all view controllers and return YES and I did like this:
- (BOOL)shouldAutorotateToInterfaceOrien开发者_运维问答tation:(UIInterfaceOrientation)interfaceOrientation {
return YES;
}
but it still doesn't work. What could possibly be wrong?
Be sure:
- Your info.plist supports all the orientations.
- All the view controllers support it as well.
- Your UITabBarController itselfs supports them.
精彩评论