I have a UINavigation base app in which I was supporting all orientations for some view controller but not for all using this code
@interface UINavigationController (Autorotation)
(BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)toInterfaceOrientation; @end
@implementation UINavigationController (Autorotation)
(BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)toInterfaceOrientation{
if ([self.visibleViewController isKindOfClass:[MWPhotoBrowser class]] || [self.visibleViewController isKindOfClass:[ZoomPictureViewController class]]) { return YES; } return (toInterfaceOrientation == UIInterfaceOrientationPortrait); } @end
It was working great but not working in IOS6. I have set all four orientations supported in my projects plist file.
Help if anyone has found some work around for.