【发布时间】:2012-09-21 23:46:38
【问题描述】:
我使用 Xcode 3.2 开发了一个 iOS 应用程序,我想发布一个支持更大 iPhone 5 屏幕的应用程序的新版本。
我在 Application Delegate 中尝试了以下操作:
[window setFrame:[[UIScreen mainScreen] bounds]];
[window addSubview:viewController.view];
[window makeKeyAndVisible];
CGRect screenBounds = [[UIScreen mainScreen] bounds];
NSLog(@"%@",[NSValue valueWithCGRect:screenBounds]);
// NSRect: {{0, 0}, {320, 480}}
如您所见,高度设置为 480pt。如何添加对 iPhone 5 更高屏幕的支持?
谢谢,
【问题讨论】:
-
Xcode 3.2 是否支持 iOS 6? iPhone 5 仅运行 iOS6,并且需要将 Default-568h@2x.png 添加到捆绑包中。我认为您需要将 Xcode 升级到最新版本。
-
通过添加额外的启动图像作为@Jessedc 建议
UIScreen可能会向您的result报告正确的高度。 -
只是我在尝试。感谢您的回复
-
感谢您的回复。我已成功完成您的指导。但我无法投票给你们的 cmets。对不起