...
|
...
|
@@ -74,7 +74,12 @@ static char imageURLStorageKey; |
|
|
dispatch_main_sync_safe(^{
|
|
|
__strong UIButton *sself = wself;
|
|
|
if (!sself) return;
|
|
|
if (image) {
|
|
|
if (image && (options & SDWebImageAvoidAutoSetImage) && completedBlock)
|
|
|
{
|
|
|
completedBlock(image, error, cacheType, url);
|
|
|
return;
|
|
|
}
|
|
|
else if (image) {
|
|
|
[sself setImage:image forState:state];
|
|
|
}
|
|
|
if (completedBlock && finished) {
|
...
|
...
|
@@ -117,7 +122,12 @@ static char imageURLStorageKey; |
|
|
dispatch_main_sync_safe(^{
|
|
|
__strong UIButton *sself = wself;
|
|
|
if (!sself) return;
|
|
|
if (image) {
|
|
|
if (image && (options & SDWebImageAvoidAutoSetImage) && completedBlock)
|
|
|
{
|
|
|
completedBlock(image, error, cacheType, url);
|
|
|
return;
|
|
|
}
|
|
|
else if (image) {
|
|
|
[sself setBackgroundImage:image forState:state];
|
|
|
}
|
|
|
if (completedBlock && finished) {
|
...
|
...
|
|