【问题标题】:Asset Catalog Launch Image Not Being Used for 4 inch simulator资产目录启动图像未用于 4 英寸模拟器
【发布时间】:2013-11-08 04:35:14
【问题描述】:

由于某种原因,当我以编程方式从资产目录中引用我的 4 英寸启动图像时,它没有被选中?它使用 3.5 的默认启动图像。有什么线索吗?

UIColor *image = [[UIColor alloc] initWithPatternImage:[UIImage imageNamed:@"LaunchImage"]];
self.view.backgroundColor = image;

【问题讨论】:

标签: ios iphone xcode image asset-catalog


【解决方案1】:

我没有使用启动图像资产目录,而是创建了另一个具有相同图像的目录并将其用作背景图像参考。

UIColor *image = [[UIColor alloc] initWithPatternImage:[UIImage imageNamed:@"Background"]];
self.view.backgroundColor = image;

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 2013-10-03
    • 2013-03-01
    • 2015-06-05
    • 1970-01-01
    • 1970-01-01
    • 2013-11-22
    • 1970-01-01
    相关资源
    最近更新 更多