mirror of
https://github.com/status-im/react-native-fast-image.git
synced 2025-02-22 19:28:32 +00:00
Remove cancellation code since sd_setImageWithURL already handles cancellation.
This commit is contained in:
parent
2e2a4175c4
commit
bd6cb0cae4
@ -12,9 +12,7 @@
|
|||||||
|
|
||||||
- (void)setSource:(FFFastImageSource *)source {
|
- (void)setSource:(FFFastImageSource *)source {
|
||||||
if (_source != source) {
|
if (_source != source) {
|
||||||
// Cancel any previous image loading in progress.
|
_source = source;
|
||||||
[self sd_cancelCurrentAnimationImagesLoad];
|
|
||||||
|
|
||||||
// Set headers.
|
// Set headers.
|
||||||
[source.headers enumerateKeysAndObjectsUsingBlock:^(NSString *key, NSString* header, BOOL *stop) {
|
[source.headers enumerateKeysAndObjectsUsingBlock:^(NSString *key, NSString* header, BOOL *stop) {
|
||||||
[[SDWebImageDownloader sharedDownloader] setValue:header forHTTPHeaderField:key];
|
[[SDWebImageDownloader sharedDownloader] setValue:header forHTTPHeaderField:key];
|
||||||
@ -56,10 +54,4 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
- (void)removeFromSuperview {
|
|
||||||
// Cancel any loading.
|
|
||||||
[self sd_cancelCurrentAnimationImagesLoad];
|
|
||||||
[super removeFromSuperview];
|
|
||||||
}
|
|
||||||
|
|
||||||
@end
|
@end
|
||||||
|
Loading…
x
Reference in New Issue
Block a user