我有一個第一的ViewController這是一個的UITabBarController,不應該被旋轉的UINavigationController ... 然後推的UIViewController應轉動......只有一些viewController在UINavigationController的iOS 6.0旋轉?
到目前爲止,我已經劃分子類的UINavigationController和實施這些方法:
- (BOOL) shouldAutorotate {
return [self.visibleViewController shouldAutorotate];
}
- (NSUInteger)supportedInterfaceOrientations {
return [self.visibleViewController supportedInterfaceOrientations];
}
所以這是孩子控制器選擇是否應該自動旋轉...... 我迄今設法阻止旋轉的的UITabBarController並允許推的UIViewController旋轉。
唯一的是,如果UIViewController處於橫向模式,當我彈出它時,UITabBarController也將處於橫向模式,直到手機處於縱向模式,它將恢復正常,而不是轉動了......
我想,當我彈出景觀的UIViewController,該的UITabBarController已經在肖像模式。
這種新的iOS 6.0用戶界面旋轉管理似乎是一個痛苦!
雖然這件事,但沒有好,我需要繼續推動的觀點,現在視圖控制器不會... – TheSquad 2013-02-13 15:06:41
但你可以展示一個導航控制器,然後推入。 – matt 2013-02-13 15:08:00
其實,如果supportedInterfaceOrientations返回0,這將讓你setStatusBarOrientation ...這將設置狀態欄,但用戶界面將保持景觀,讓我的東西真的醜陋(我不能似乎能夠旋轉UI即使在很好的位置...) – TheSquad 2013-02-13 15:12:33