【发布时间】:2017-07-01 10:07:14
【问题描述】:
我只想为UIButton 设置图像并为其创建IBOutlet。我上面有一个加载器,当加载图像时,加载器将停止并为该按钮分配一个新图像。调用代码时,占位符图片保留,不加载url图片
[_Image1 sd_setBackgroundImageWithURL:[NSURL URLWithString:[arrayGallery valueForKey:@"link"][0]] forState:UIControlStateNormal placeholderImage:[UIImage imageNamed:@"blurred-background"] completed:^(UIImage *image, NSError *error, SDImageCacheType cacheType, NSURL *imageURL) {
[_ImageLoader1 stopAnimating];
[_ImageLoader1 removeFromSuperview];
}];
【问题讨论】:
标签: ios objective-c input-button-image