gpt4 book ai didi

swift - SDWebImage swift 崩溃

转载 作者:搜寻专家 更新时间:2023-10-31 22:52:40 25 4
gpt4 key购买 nike

似乎如果我在完成的 block 中使用“self”,它就会崩溃。

self.imageView.sd_setImageWithURL(MYIMAGEURL
, placeholderImage: nil
, options: SDWebImageOptions.RetryFailed
, progress: {(receivedSize: Int!, expectedSize: Int!) in

}
, completed:{(image: UIImage?, error: NSError?, cacheType: SDImageCacheType!, imageURL: NSURL?) in
if image {
UIView.transitionWithView(self.imageView
, duration: 0.3
, options: UIViewAnimationOptions.AllowUserInteraction | UIViewAnimationOptions.TransitionCrossDissolve
, animations: {

}
, completion: {(finished) in

})
}
})

最佳答案

SDWebImageModule 是一个积极开发的开源组件。在这种情况下,raise a bug on GitHub 要好得多。 .开发人员已经发布了一些版本 fix Xcode6 and Swift issues .

关于swift - SDWebImage swift 崩溃,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/24948480/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com