gpt4 book ai didi

ios - Xcode 10 : The Image set 'customloading' reference a file "mygif.gif" , 但该文件没有有效的扩展名

转载 作者:塔克拉玛干 更新时间:2023-11-02 22:00:37 24 4
gpt4 key购买 nike

我将我的 xcode9 更新为 xcode10,然后我的应用程序上的 gif 突然看不到我的 gif。然后当我去我的 Assets 时。出现。

I update my

class CustomLoading: UIView {

static let instance = CustomLoading()
var viewColor: UIColor = .brown
var setAlpha: CGFloat = 2.0
var gifName: String = "customloading"

lazy var transparentView: UIView = {

let transparentView = UIView(frame: UIScreen.main.bounds)
transparentView.backgroundColor = UIColor.white.withAlphaComponent(setAlpha)
transparentView.isUserInteractionEnabled = false
return transparentView

}()

最佳答案

xcode 10 不支持 Assets 上的 gif,所以我在 Assets 文件夹外调用它

关于ios - Xcode 10 : The Image set 'customloading' reference a file "mygif.gif" , 但该文件没有有效的扩展名,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/53454598/

24 4 0
文章推荐: android - 获取资源编号的值时没有包标识符
文章推荐: javascript - 如何在 iPhone 上不使用 jQuery 获取 originalEvent
文章推荐: JavaScript 和 DOM : Why "" += "" += "