繁体   English   中英

通用 iOS 应用程序在 iPad 设备/模拟器上测试 iPhone 目标

[英]Universal iOS app test iPhone target on iPad device/simulator

我正在尝试在 iPad 上测试我的通用应用程序的 iPhone 部分,我在 Mac OSX Lion 上使用 Xcode 4.1

所以,我将目标构建设置中的“目标设备系列”更改为仅限 iPhone。 我检查了它是否在所有配置上(调试和发布)

When i connect my iPad and run the app, the app runs in the iPhone environment on iPad (i only see the black frame) and then it crashes, because its loading the AppDelegate of the iPad not the iPhone which contains an UISplitViewController so it crashes .

如何引导通用应用使用 iPhone AppDelegate? 我应该以编程方式进行吗? 或者我必须做的目标中有任何其他设置。

感谢帮助。

似乎解决此问题的唯一方法是将 info.plist 文件中的属性“Main nib file base name (iPad)”更改为与“Main nib file base name”相同,两者都指向 iPhone Main Window

您应该将项目和目标的目标设备系列设置为iphone/ipad ,当您运行应用程序 select 时,您将从下拉列表中运行当前设备系列。

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM