我正在开发支持横向和纵向两种模式的应用程序,我的启动屏幕在 ios 9 之前是横向的,没问题,但 ios 9 启动屏幕正在以纵向模式启动
最佳答案
我遇到了同样的问题,我终于解决了。
首先,从 info.plist 中删除关键的“Supported interface orientations”。
然后在info.plist中添加关键字“Initial interface orientation”。将键值设置为“横向(右主页按钮)”。
最后,添加到您的 appDelegate.mm。
-(NSUInteger)application:(UIApplication *)application supportedInterfaceOrientationsForWindow:(UIWindow *)window{
return UIInterfaceOrientationMaskAll;
}
关于ios 9 启动屏幕正在以纵向模式启动,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/32990641/