Skip to content

Commit de7ba8d

Browse files
author
Antti Kortetmaa
committed
Removed updateWebPOptionsToConfig from the public API of SDImageWebPCoder
1 parent e330f22 commit de7ba8d

File tree

2 files changed

+19
-18
lines changed

2 files changed

+19
-18
lines changed

SDWebImageWebPCoder/Classes/SDImageWebPCoder.h

Lines changed: 0 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -12,29 +12,11 @@
1212
@import SDWebImage;
1313
#endif
1414

15-
#if __has_include("webp/decode.h") && __has_include("webp/encode.h") && __has_include("webp/demux.h") && __has_include("webp/mux.h")
16-
#import "webp/decode.h"
17-
#import "webp/encode.h"
18-
#import "webp/demux.h"
19-
#import "webp/mux.h"
20-
#elif __has_include(<libwebp/decode.h>) && __has_include(<libwebp/encode.h>) && __has_include(<libwebp/demux.h>) && __has_include(<libwebp/mux.h>)
21-
#import <libwebp/decode.h>
22-
#import <libwebp/encode.h>
23-
#import <libwebp/demux.h>
24-
#import <libwebp/mux.h>
25-
#else
26-
@import libwebp;
27-
#endif
28-
2915
/**
3016
Built in coder that supports WebP and animated WebP
3117
*/
3218
@interface SDImageWebPCoder : NSObject <SDProgressiveImageCoder, SDAnimatedImageCoder>
3319

3420
@property (nonatomic, class, readonly, nonnull) SDImageWebPCoder *sharedCoder;
3521

36-
- (void) updateWebPOptionsToConfig:(WebPConfig * _Nonnull)config
37-
maxFileSize:(NSUInteger)maxFileSize
38-
options:(nullable SDImageCoderOptions *)options;
39-
4022
@end

Tests/SDWebImageWebPCoderTests.m

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,19 @@
1313
#import <SDWebImageWebPCoder/SDWebImageWebPCoderDefine.h>
1414
#import <Expecta/Expecta.h>
1515
#import <objc/runtime.h>
16+
#if __has_include("webp/decode.h") && __has_include("webp/encode.h") && __has_include("webp/demux.h") && __has_include("webp/mux.h")
17+
#import "webp/decode.h"
18+
#import "webp/encode.h"
19+
#import "webp/demux.h"
20+
#import "webp/mux.h"
21+
#elif __has_include(<libwebp/decode.h>) && __has_include(<libwebp/encode.h>) && __has_include(<libwebp/demux.h>) && __has_include(<libwebp/mux.h>)
22+
#import <libwebp/decode.h>
23+
#import <libwebp/encode.h>
24+
#import <libwebp/demux.h>
25+
#import <libwebp/mux.h>
26+
#else
27+
@import libwebp;
28+
#endif
1629

1730
const int64_t kAsyncTestTimeout = 5;
1831

@@ -31,6 +44,12 @@ @interface SDWebPCoderFrame : NSObject
3144
@property (nonatomic, assign) NSUInteger blendFromIndex; // The nearest previous frame index which blend mode is WEBP_MUX_BLEND
3245
@end
3346

47+
@interface SDImageWebPCoder ()
48+
- (void) updateWebPOptionsToConfig:(WebPConfig * _Nonnull)config
49+
maxFileSize:(NSUInteger)maxFileSize
50+
options:(nullable SDImageCoderOptions *)options;
51+
@end
52+
3453
@implementation SDWebImageWebPCoderTests
3554

3655
+ (void)setUp {

0 commit comments

Comments
 (0)