iOS 6 UITabBarController supported orientation with current UINavigation controller

后端 未结 4 1364
长情又很酷
长情又很酷 2020-11-30 21:35

I have an iPhone app I am updating to iOS 6 that is having rotation issues. I have a UITabBarController with 16 UINavigationCotrollers. Most of the

4条回答
  •  一个人的身影
    2020-11-30 22:23

    I had issue that some View controllers in the navigation stack support all the orientations, some only portrait, but UINavigationController was returning all app supported orientations, this little hack helped me. I'm not sure if this is intended behavior or what

    @implementation UINavigationController (iOS6OrientationFix)
    
    -(NSUInteger) supportedInterfaceOrientations {
        return [self.topViewController supportedInterfaceOrientations];
    }
    
    @end
    

提交回复
热议问题