简体   繁体   English

Xcode 6.1关于在资产目录中启动图像的警告

[英]Xcode 6.1 Warning about Launch Image in Asset Catalog

I am using Xcode 6.1 to create a app supporting iOS 6 and later. 我正在使用Xcode 6.1创建一个支持iOS 6及更高版本的应用程序。

.In target's "App Icons and Launch Images", I set the Launch Images Source as "Use Asset Catalog" and Launch Screen File to "LaunchScreen". 。在目标的“应用程序图标和启动图像”中,我将启动图像源设置为“使用资产目录”并将启动屏幕文件设置为“LaunchScreen”。

In Images.xcassets which created by Xcode, I fill in every box for "LaunchImage", but there's always a warning message: 在由Xcode创建的Images.xcassets中,我填写“LaunchImage”的每个框,但总是有一条警告消息:

Retina 4-inch Support. Retina 4英寸支持。 Applications using Launch Screen Files and targeting iOS 7.1 and earlier need to also include a Launch Image in an Asset Catalog. 使用启动屏幕文件并定位iOS 7.1及更早版本的应用程序还需要在资产目录中包含启动图像。

I created another Image Set named as "Default" and fill in the "Retina 4 2x" box with expected image. 我创建了另一个名为“默认”的图像集,并在预期图像中填入“Retina 4 2x”框。 But the warning message still there. 但警告信息仍在那里。

Any hint to clear this warning? 有任何提示要清除此警告吗? Thanks. 谢谢。

I ran into the exact same problem this morning. 今天早上我遇到了同样的问题。 Here's how I fixed it. 这就是我修复它的方法。

  1. Select your Target in the project navigator. 在项目导航器中选择目标。 Under the General tab, you should see the section for App Icons and Launch Images . 在“ 常规”选项卡下,您应该看到“ 应用程序图标”和“启动图像”部分 Where you see Launch Images Source, click 'Use Asset Catalog'. 如果您看到启动图像源,请单击“使用资产目录”。

  2. You will then see Migrate launch images to an asset catalog dialogue. 然后,您将看到将启动图像迁移到资产目录对话框。 Click 'Migrate'. 点击“迁移”。

  3. Make sure that your Launch Images Source on the previous screen points to the right image set in your asset catalog. 确保上一屏幕上的“ 启动图像源 ”指向资产目录中的右图像集。 In your case, you would set it to 'Default'. 在您的情况下,您将其设置为“默认”。

That should take care of the warning. 那应该照顾警告。 Hope that helps! 希望有所帮助!

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

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