Commit Graph

1893 Commits

Author SHA1 Message Date
DreamPiggy 65537c4983 Remove the check for URLProtocol in custom loader to avoid crash on iOS 8. Let URLSession itself or download operation to parse the result. 2018-04-25 14:21:38 +08:00
DreamPiggy 830fb0d358 Merge branch 'fix_coder_implementation' into 5.x 2018-04-25 14:14:41 +08:00
DreamPiggy 0832da8d7c Avoid duplicated force decode for progressive WebP images 2018-04-25 13:39:06 +08:00
DreamPiggy 072b832375 Fix the issue for progressive decoding that do not parse the correct animated image scale. Update all coders 2018-04-25 12:59:44 +08:00
DreamPiggy a22a0e25f7 Merge branch 'master' of https://github.com/rs/SDWebImage into 5.x
# Conflicts:
#	SDWebImage/SDImageCache.h
2018-04-25 10:56:51 +08:00
DreamPiggy 22e532c9e3 Fix function storeImageDataToDisk description 2018-04-24 21:32:26 +08:00
Bogdan Poplauschi bfa9670c2d
Merge pull request #2301 from plokijuhhb/plokijuhhb-patch-2
Fix function storeImageDataToDisk description
2018-04-24 16:05:57 +03:00
Bogdan Poplauschi 778322daf9
Merge pull request #2296 from dreampiggy/refactor_manager_logic
Refactor manager logic - Also suppoort ignore cache query
2018-04-24 15:39:17 +03:00
Bogdan Poplauschi e8ce9e89c5
Merge pull request #2299 from dreampiggy/feature_cache_namespace_prefix
Add the ability to custom the cache namespace prefix
2018-04-24 08:57:43 +03:00
plokijuhhb 745dc38986
Fix function storeImageDataToDisk description
New Pull Request Checklist

 I have read and understood the CONTRIBUTING guide

 I have read the Documentation

 I have searched for a similar pull request in the project and found none

 I have updated this branch with the latest master to avoid conflicts (via merge from master or rebase)

 I have added the required tests to prove the fix/feature I am adding

 I have updated the documentation (if necessary)

 I have run the tests and they pass

 I have run the lint and it passes (pod lib lint)

This merge request fixes / reffers to the following issues: ...

Pull Request Description

####Description
There are some problems in this description

Or using marco like SDWebImageCompat avoid deadlocks

#ifndef dispatch_queue_sync_safe
#define dispatch_queue_sync_safe(queue, block)\
if (strcmp(dispatch_queue_get_label(DISPATCH_CURRENT_QUEUE_LABEL), dispatch_queue_get_label(queue)) == 0) {\
block();\
} else {\
dispatch_sync(queue, block);\
}
#endif
2018-04-24 00:33:54 +08:00
DreamPiggy cfd68422dc Refactor current manager's internal implementation for that `loadImageWithURL:`. Separate to 3 parts (context preprocess, cache process, download process). Also introduce `SDWebImageFromLoaderOnly` feature to ignore cache at all
This is useful for some custom image loader where user does not need memory cache at all.
2018-04-21 15:12:17 +08:00
DreamPiggy bf85c53b77 Remove the unused header files in download operation 2018-04-21 14:33:02 +08:00
DreamPiggy 8269a0cd8e Add the ability to custom the cache namespace prefix. Which allow user to specify the correct namespace prefix by their own 2018-04-21 14:00:46 +08:00
DreamPiggy 3c478cbdf2 Merge branch 'refactor_loader_protocol' into 5.x 2018-04-21 10:53:42 +08:00
DreamPiggy 4b69f49c13 Rename the progressive download helper function to using `operation` instead of pass a progressive coder to make the logic more suitable for the caller 2018-04-21 10:53:23 +08:00
DreamPiggy be8fce5ddb Fix the download operation to specify correct error code for bad image data 2018-04-20 11:05:53 +08:00
DreamPiggy 70d9d31c0f Fix the wrong options issue 2018-04-20 11:05:35 +08:00
Bogdan Poplauschi efb764d587
Merge pull request #2265 from dreampiggy/improvement_module_framework
Improvement module framework
2018-04-19 14:13:44 +03:00
DreamPiggy 8ed4dcb884 Fix the warning of high version API on macOS 2018-04-19 17:51:55 +08:00
DreamPiggy 9c11886dc0 Update the test project to use modular headers instead of massive headers... 2018-04-19 17:25:39 +08:00
DreamPiggy 55e4ce35bd Replace all the demo project to use `#import <SDWebImage/SDWebImage.h>` module headers instead of massive headers 2018-04-19 17:25:39 +08:00
DreamPiggy f81480189d Add modulemap files for SDWebImage to support modular framework, move the WebP & GIF into subdirectory to make Podspec works 2018-04-19 17:25:39 +08:00
DreamPiggy 31b3726439 Merge branch 'master' of https://github.com/rs/SDWebImage into 5.x
# Conflicts:
#	SDWebImage/SDWebImageCodersManager.m
2018-04-19 17:04:23 +08:00
Bogdan Poplauschi af0eaccbc5 Merge pull request #2292 from dreampiggy/refactor_cache_webcache_protocol
Fix the custom cache protocol naming
2018-04-19 10:39:39 +03:00
Bogdan Poplauschi eded5f026c Merge pull request #2293 from dreampiggy/refactor_naming_NSImge_category
Renaming the NSImage category naming to `NSImage+Compatibility`
2018-04-19 10:26:51 +03:00
Bogdan Poplauschi 09cb3ec083
Merge pull request #2256 from dreampiggy/feature_custom_loader
Feature custom image loader - Supports loader protocol
2018-04-19 10:07:06 +03:00
Bogdan Poplauschi 8154d16bb2
Merge pull request #2274 from dreampiggy/fix_coders_array
Fix the thread-safe issue for coders manager.
2018-04-19 08:34:43 +03:00
DreamPiggy 7cf58ad7c5 Renaming the NSImage category naming to `NSImage+Compatibility`, because it's only used for Cross-platform compatibility code. `Additions` is too wide 2018-04-18 21:14:34 +08:00
DreamPiggy d5074429f0 Add tests for custom loader protocol, using a test loader to specify loader function 2018-04-18 20:46:00 +08:00
DreamPiggy 60759f812a Refactor to only use one publish protocol for custom loader. Renaming image downloader description to loader 2018-04-18 20:46:00 +08:00
DreamPiggy 8292c0c1e9 Update the loader protocol to refactor the common image decoding process. 2018-04-18 20:26:14 +08:00
DreamPiggy 57db312cc5 Add `SDWebImageLoader` protocol for custom image loader. Also introduce the `SDWebImageLoadersManager` to manage multiple loaders with priority 2018-04-18 20:26:14 +08:00
DreamPiggy a6bdba724e Fix all cache test 2018-04-18 19:24:23 +08:00
DreamPiggy 734c6821d5 Rename the cache protocol to `SDImageCache` protocol 2018-04-18 19:24:23 +08:00
DreamPiggy bee5425078 Rename the caches manager without `Web` prefix 2018-04-18 19:24:22 +08:00
Bogdan Poplauschi 5426a720f7
Merge pull request #2278 from dreampiggy/refactor_cache_webcache_protocol
Refactor cache - Support custom web cache
2018-04-18 14:06:50 +03:00
Bogdan Poplauschi 00f9f3a597
Merge pull request #2290 from dreampiggy/refactor_error_code
Refactor error code
2018-04-18 10:44:07 +03:00
Bogdan Poplauschi 6e5b9634a8
Merge pull request #2287 from dreampiggy/fix_default_config_readonly
Fix the default download config & cache config to readonly
2018-04-18 10:41:43 +03:00
DreamPiggy 5a32da7953 Move the complicated built-in decode process into a global function to allow user who custom web cache use it 2018-04-18 14:59:34 +08:00
DreamPiggy 632a2bb110 Rename all the image cache block naming with the unite naming (Prefix `SDImageCache`) 2018-04-18 14:40:56 +08:00
DreamPiggy 2c7d1a465a Update the tests for web cache protocol and caches manager 2018-04-18 14:40:56 +08:00
DreamPiggy 1220f73507 Expose the sync version of remove API 2018-04-18 14:40:56 +08:00
DreamPiggy 9f770b6c19 Refactor to support custom image cache used for web manager. Supports caches manager with multiple caches and op policy 2018-04-18 14:40:56 +08:00
DreamPiggy f7af36f3bd Merge branch 'master' of https://github.com/rs/SDWebImage into 5.x
# Conflicts:
#	SDWebImage/SDImageCache.h
#	SDWebImage/SDImageCache.m
#	SDWebImage/SDWebImageManager.m
2018-04-18 14:37:15 +08:00
Bogdan Poplauschi 96ec9719a0
Merge pull request #2281 from dreampiggy/feature_scale_download_cache_options
Add `SDImageCacheScaleDownLargeImages` to allow cache to scale down large images if need
2018-04-18 09:22:13 +03:00
DreamPiggy 60d58ef977 Refactor all current custom error in SDWebImageErrorDomain with error code. Also using NS_ERROR_ENUM to provide better Swift API 2018-04-18 13:26:20 +08:00
DreamPiggy 77426d127f Fix the default download config & cache config to readonly. You can modify the property of config, but not the override the default config instance itself. 2018-04-17 19:28:41 +08:00
DreamPiggy cb7d5288c3 Save the DerivedData folder for iOS & macOS test finished, only upload the correct test 2018-04-17 18:03:10 +08:00
Bogdan Poplauschi 1bc4662bde Merge pull request #2282 from dreampiggy/refactor_memory_cache_disk_cache
Refactor cache - Support custom memory cache & disk cache
2018-04-17 12:14:06 +03:00
DreamPiggy f0868ccfe8 Still fix the codecov issue by Clean all DerivedData before the test 2018-04-17 16:57:37 +08:00