From 94217b294ccd75a34787eb04d6e273e99536e45b Mon Sep 17 00:00:00 2001 From: 重庆迈尖科技有限公司 Date: 星期三, 30 一月 2019 15:12:32 +0800 Subject: [PATCH] no message --- Pods/SDWebImage/SDWebImage/UIImageView+WebCache.h | 20 +++++++++----------- 1 files changed, 9 insertions(+), 11 deletions(-) diff --git a/Pods/SDWebImage/SDWebImage/UIImageView+WebCache.h b/Pods/SDWebImage/SDWebImage/UIImageView+WebCache.h index b1d954f..412cca0 100644 --- a/Pods/SDWebImage/SDWebImage/UIImageView+WebCache.h +++ b/Pods/SDWebImage/SDWebImage/UIImageView+WebCache.h @@ -7,9 +7,6 @@ */ #import "SDWebImageCompat.h" - -#if SD_UIKIT || SD_MAC - #import "SDWebImageManager.h" /** @@ -54,7 +51,7 @@ * * @param url The url for the image. */ -- (void)sd_setImageWithURL:(nullable NSURL *)url; +- (void)sd_setImageWithURL:(nullable NSURL *)url NS_REFINED_FOR_SWIFT; /** * Set the imageView `image` with an `url` and a placeholder. @@ -66,7 +63,7 @@ * @see sd_setImageWithURL:placeholderImage:options: */ - (void)sd_setImageWithURL:(nullable NSURL *)url - placeholderImage:(nullable UIImage *)placeholder; + placeholderImage:(nullable UIImage *)placeholder NS_REFINED_FOR_SWIFT; /** * Set the imageView `image` with an `url`, placeholder and custom options. @@ -79,7 +76,7 @@ */ - (void)sd_setImageWithURL:(nullable NSURL *)url placeholderImage:(nullable UIImage *)placeholder - options:(SDWebImageOptions)options; + options:(SDWebImageOptions)options NS_REFINED_FOR_SWIFT; /** * Set the imageView `image` with an `url`. @@ -111,7 +108,7 @@ */ - (void)sd_setImageWithURL:(nullable NSURL *)url placeholderImage:(nullable UIImage *)placeholder - completed:(nullable SDExternalCompletionBlock)completedBlock; + completed:(nullable SDExternalCompletionBlock)completedBlock NS_REFINED_FOR_SWIFT; /** * Set the imageView `image` with an `url`, placeholder and custom options. @@ -155,7 +152,9 @@ completed:(nullable SDExternalCompletionBlock)completedBlock; /** - * Set the imageView `image` with an `url` and optionally a placeholder image. + * Set the imageView `image` with an `url` and custom options. The placeholder image is from previous cached image and will use the provided one instead if the query failed. + * This method was designed to ensure that placeholder and query cache process happened in the same runloop to avoid flashing on cell during two `setImage:` call. But it's really misunderstanding and deprecated. + * This can be done by using `sd_setImageWithURL:` with `SDWebImageQueryDiskSync`. But take care that if the memory cache missed, query disk cache synchronously may reduce the frame rate * * The download is asynchronous and cached. * @@ -169,12 +168,13 @@ * is nil and the second parameter may contain an NSError. The third parameter is a Boolean * indicating if the image was retrieved from the local cache or from the network. * The fourth parameter is the original image url. + * @deprecated consider using `SDWebImageQueryDiskSync` options with `sd_setImageWithURL:` instead */ - (void)sd_setImageWithPreviousCachedImageWithURL:(nullable NSURL *)url placeholderImage:(nullable UIImage *)placeholder options:(SDWebImageOptions)options progress:(nullable SDWebImageDownloaderProgressBlock)progressBlock - completed:(nullable SDExternalCompletionBlock)completedBlock; + completed:(nullable SDExternalCompletionBlock)completedBlock __deprecated_msg("This method is misunderstanding and deprecated, consider using `SDWebImageQueryDiskSync` options with `sd_setImageWithURL:` instead"); #if SD_UIKIT @@ -192,5 +192,3 @@ #endif @end - -#endif -- Gitblit v1.8.0