* [ASDisplayNode] Ensure all subclasses are using base class __instanceLock__ and not re-defining their own.
This also moves the @package definition of the instance variable to +FrameworkPrivate instead of Internal.h,
because Internal.h should ideally not be used outside of the ASDisplayNode file setup. This has greatly reduced
the number of imports of Internal.h.
* [ASDisplayNode] Add ASDisplayNode+FrameworkSubclasses.h to share __instanceLock__ definition.
* Replace fetch data with preload terminology
- Deprecate `-fetchData` and `-clearFetchedData` in favor of `-preload` and `-clearPreloadedData`
- Move `-setNeedsPreload`, `-recursivelyPreload` and `-recursivelyClearPreloadedData` to ASDisplayNode+FrameworkPrivate.h
- Update internal implementation, comments and tests
* Folllow up on #2642:
- Remove -preload and -clearPreloadedData in favor of -didEnterPreloadState and -didExitPreloadState.
- -didEnterPreloadState and -didExitPreloadState call the deprecated -fetchData and -clearFetchedData methods if they are overriden.
* Missed one in a test
* Get rid of behavior change for now.
* Revert more behavior changes, fix tests.
* Don't need these anymore.
* [ASRunLoopQueue - Performance] Add ASDeallocQueue for efficient object teardown.
This measurably reduces block overhead and context switching. In the layout benchmark,
it increases ops/s while actually reducing CPU utilization. This suggests that we are
now at a lock-bounded local maximum, at least for tri-core devices.
* [ASDeallocQueue] Update convenience helper method and adopt in ASImageNode etc.
* [ASDeallocQueue] Reimplement the queue using a timer-based runloop.
* [Debugging] Re-enable ASDisplayNode Event Log.
* [ASDeallocQueue] Final refinements, comments, code minimization.
* [ASDeallocQueue] Fix for lock release needed in early return (refactoring typo from last commit)
* Remove old deprecated methods. Will restore ones that were removed recently based on PR.
* Update example to use non-deprecated method.
* Don't remove locking / unlocking, insets or willDisplayNode deprecated methods yet.
* Renamed range update callbacks
We finally settled on
didEnter/ExitDisplayState
didEnter/ExitPreloadState
didEnter/ExitVisibleState
This change is meant to unify the range update methods to relate to each
other and hopefully be a bit more self explanatory.
* Guarantee interface callbacks happen on main.
* move fetchData / clearFetchedData to default implementations
* Move deprecated methods to new deprecated category
* Don't bring in cocoapod change.
* Nits
* Capetalize
Summary:
Use NSData as key
Add chunking of files
Add support for Animated Images
This adds support for GIF playback in ASDK. It's not currently ready
for merging to public ASDK – for one the GIF decompression may make
more sense in PINRemoteImage.
Removed duration as it wasn't used
Make cover image lazily loaded
Differential Revision: https://phabricator.pinadmin.com/D82033
[ASDisplayNode] Placeholders should always be recreated if returning to cleared nodes, and remain until ASNetwork/MultiplexImageNode finish loading their image from the network.
If previously-displayed contents is gone (e.g. clearContents), and is not finished displaying
by the time the node is onscreen, recreate the placeholder immediately.