From 1b4b6a3f02a79abfa7e77824a3f6c9b202e7493b Mon Sep 17 00:00:00 2001 From: Adam Bell Date: Mon, 3 Jun 2019 08:56:48 -0700 Subject: [PATCH] Fix Opting-Out of Linking with Photos Framework (#1519) --- Source/ASMultiplexImageNode.h | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/Source/ASMultiplexImageNode.h b/Source/ASMultiplexImageNode.h index 503b5cbf59..aad731ddda 100644 --- a/Source/ASMultiplexImageNode.h +++ b/Source/ASMultiplexImageNode.h @@ -9,7 +9,14 @@ #import #import + +#if AS_USE_PHOTOS #import +#else +@class PHAsset; +@class PHImageManager; +@class PHImageRequestOptions; +#endif NS_ASSUME_NONNULL_BEGIN @@ -125,10 +132,11 @@ typedef NS_ENUM(NSUInteger, ASMultiplexImageNodeErrorCode) { /** * @abstract The image manager that this image node should use when requesting images from the Photos framework. If this is `nil` (the default), then `PHImageManager.defaultManager` is used. - + * @see `+[NSURL URLWithAssetLocalIdentifier:targetSize:contentMode:options:]` below. */ @property (nullable, nonatomic) PHImageManager *imageManager API_AVAILABLE(ios(8.0), tvos(10.0)); + @end @@ -249,6 +257,9 @@ didFinishDownloadingImageWithIdentifier:(ASImageIdentifier)imageIdentifier @end #pragma mark - + +#if AS_USE_PHOTOS + @interface NSURL (ASPhotosFrameworkURLs) /** @@ -266,4 +277,6 @@ didFinishDownloadingImageWithIdentifier:(ASImageIdentifier)imageIdentifier @end +#endif + NS_ASSUME_NONNULL_END