xcode:使用带情节提要的 iPad 模拟器运行时出现空白屏幕
似乎是一个基本问题,但我就是无法弄清楚:
xcode 5.0 iOS app。最终我将拥有 iPad 专用的故事板,但现在我只想在所有设备上使用 iPhone 故事板。当设置为“iPhone 5.0 模拟器”时,模拟器运行良好,但当作为“iPad 5.0 模拟器”运行时,它只显示空白屏幕。
我有名为 MainStoryboard_iPhone.storyboard 和 MainStoryboard_iPad.storyboard 的文件。 iPad 故事板不包含任何具体内容,因为我只研究 iPhone 故事板。 (这当然就是为什么我在运行 iPad 模拟器时出现空白屏幕。)但是,我似乎找不到一种方法来“禁用”iPad 故事板并让它在运行 iPad 模拟器时使用 iPhone 故事板。
我尝试删除该文件(导致编译错误)并将 iPhone 故事板软链接到 iPad 故事板(导致内部错误)。
在项目“摘要”下,我将“设备”设置为“iPhone”。
在“构建设置”下,我将“目标设备系列”设置为“iPhone”。
有什么想法吗?
Seems like a basic question but I just can't figure it out:
xcode 5.0 iOS app. Eventually I'll have an iPad-specific storyboard but for now I just want to use the iPhone storyboard on all devices. The simulator runs fine when set to "iPhone 5.0 simulator" but when run as "iPad 5.0 simulator" it just shows a blank white screen.
I have files called MainStoryboard_iPhone.storyboard and MainStoryboard_iPad.storyboard. The iPad storyboard contains nothing specific because I've been working only on the iPhone storyboard. (This of course is why I get the blank screen when running the iPad simulator.) However, I can't seem to find a way to "disable" the iPad storyboard and have it use the iPhone storyboard when running the iPad simulator.
I've tried removing the file (results in compile error) and soft linking the iPhone storyboard to the iPad one (results in an internal error).
Under the project "Summary" I have "Devices" set to "iPhone".
Under my "Build Settings" I have "Targeted Device Family" set to "iPhone".
Any ideas?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
在项目设置下将 MainStoryboard 的目标从 MainStoryboard_iPad.storyboard 更改为 MainStoryboard_iPhone.storyboard
under the Project settings change the target of the MainStoryboard from MainStoryboard_iPad.storyboard to MainStoryboard_iPhone.storyboard