使用Xcode 6编译的iPhone应用程序在iPad上作为Universal运行 [英] iPhone app compiled with Xcode 6 on runs as Universal on iPad

查看:133
本文介绍了使用Xcode 6编译的iPhone应用程序在iPad上作为Universal运行的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个仅为iPhone系列开发的应用程序,我曾经在iPad上运行它来测试它在iPhone 4s上的外观(因为它推出了iPhone 4s分辨率,尺寸,以及'2x'圆形按钮全屏支持)。但是,现在当我在iOS 8的iPad上运行它时,Xcode会忽略所有构建设置并像iPad一样运行它。我的故事板限制不适用于iPad屏幕。

I have got an app developed for iPhone family only, and I used to run it on iPad to test how it will look on iPhone 4s (since it launched with iPhone 4s resolution, size, and else '2x' round button for fullscreen support). However, now when I run it on my iPad with iOS 8, Xcode ignores all build settings and runs it as for iPad. My storyboard constraints were not projected for iPad screen.

我有:


  1. 在项目设置的常规选项卡上设备选项设置为 iPhone

  2. 主要故事板文件名主要故事板文件名已从 Info-plist

  3. iPad的所有应用程序图标和启动图像都已删除

  4. 启动屏幕文件选项使用大小类设置为,并且仅为iPhone生成资产

  1. Devices option set to iPhone on General tab in project settings
  2. Main storyboard file name and Main storyboard file name are removed from Info-plist
  3. All App Icons and Launch Images for iPad are deleted
  4. In Launch Screen File the option Use Size Classes set to NO, and the assets are generated for iPhone only

这是正常行为吗?我想像以前一样用我的iPad来测试iPhone 4s的分辨率。我确信我的应用程序不会因此而变得普及,但我认为这是一个问题。

Is that a normal behavior? I want to use my iPad as before to test iPhone 4s resolution. I am sure that my app won't become universal because of that, but nevertheless I think this is a problem.

推荐答案

在iOS 8.0,8.0.1和8.0.2中使用启动屏幕文件将使您普及。

The use of Launch Screen File in iOS 8.0, 8.0.1 and 8.0.2 will make you universal.

这是一个已知错误并在iOS 8.1中修复,因为您只能使用带有启动图像的资产目录。

This is a know bug and fixed in iOS 8.1, for you only option is to use assets catalog with a launch images.

或者您可以在启动文件中添加设备修改器名称,如< launchNib> ~iphone.nib

Or you can add the device modifier in the Launch file name, like <launchNib>~iphone.nib

这篇关于使用Xcode 6编译的iPhone应用程序在iPad上作为Universal运行的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆