【发布时间】:2014-12-01 20:32:05
【问题描述】:
我正在开发一个有大约 12 个视图的应用程序。我希望一些是纵向的,而另一些是横向的。
如何将某些视图的方向锁定为纵向而将其他视图的方向锁定为横向?
我尝试了前面示例中的以下代码,但它没有锁定方向。
[[UIDevice currentDevice] setValue:
[NSNumber numberWithInteger: UIInterfaceOrientationLandscapeLeft]
forKey:@"orientation"];
【问题讨论】:
标签: ios xcode orientation portrait