【发布时间】:2015-04-30 08:29:07
【问题描述】:
我的应用有问题。我无法锁定我的应用程序的方向。我需要做的就是将一个视图控制器锁定为横向模式,其余的都是纵向的。
这是我的应用程序的层次结构。
*Navigation Controller
*TabBarController
*ViewControllers
【问题讨论】:
-
你的代码在哪里?
-
这是我使用的代码 -(BOOL)shouldAutorotate{ return NO; } - (NSUInteger)supportedInterfaceOrientations{ 返回 UIInterfaceOrientationMaskLandscape; } - (UIInterfaceOrientation)preferredInterfaceOrientationForPresentation{ return UIInterfaceOrientationLandscapeLeft; }
-
您可以编辑您的问题以发布代码。
标签: ios ios7 ios8 orientation