【发布时间】:2012-10-08 16:55:19
【问题描述】:
我希望能够将我的 ipad 上的初始屏幕旋转为左右横向。 我在我的 .plist 文件中启用了横向左右方向。我为 LandscapeRight 和 LandscapeLeft 添加了 4 个文件:
Default-LandscapeRight@2x~ipad.png
Default-LandscapeLeft@2x~ipad.png
Default-LandscapeRight~ipad.png
Default-LandscapeLeft~ipad.png
虽然这不重要,但在我的 rootviewcontroller 中我有:
- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation {
return (interfaceOrientation == UIInterfaceOrientationLandscapeRight || interfaceOrientation == UIInterfaceOrientationLandscapeLeft);
return ( UIInterfaceOrientationIsLandscape( interfaceOrientation ) );
}
启动画面加载,但不旋转。 我做错了什么?
【问题讨论】:
-
您可以为此使用自定义启动画面。
-
@SarafarazBabi 请详细说明。我认为定义横向左右启动画面是自定义启动画面
-
我的意思是你可以为启动屏幕创建一个类并将其作为 rootviewcontroller 传递,1 或 2 秒后只需推动你的 homeview 控制器...并在启动屏幕类中管理 shouldautorotate...明白了吗?
-
@SarafarazBabi 好主意!谢谢!我想知道为什么我的方法不起作用?
-
是否加载了正确的屏幕,或者您只是在旋转已经可见时缺少旋转?
标签: ios splash-screen