UITabbar application with different orientations

I have an iPad TabBarApplication. I have subclassed the TabbarController so that the application responds to a change in orientation:

@implementation frankenlandTabBarController

- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation {
    return (
            interfaceOrientation == UIInterfaceOrientationPortrait || 
            interfaceOrientation == UIInterfaceOrientationLandscapeLeft || 
            interfaceOrientation == UIInterfaceOrientationLandscapeRight
            );
}


@end

Now the problem is that I do not want all the viewcontrollers of my tabbarapp in these orientations.

overwriting a method shouldAutorotateToInterfaceOrientationin one controller has no effect.

any ideas?

thank!

+3
source share
1 answer

tabBar, . TabBar, () . ViewController TabBarController.

+3

Source: https://habr.com/ru/post/1773405/


All Articles