mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-11-25 17:43:18 +00:00
Update all the files in the Details group
This commit is contained in:
parent
309ecca444
commit
c010ddad3b
@ -9,6 +9,8 @@
|
||||
#import <AsyncDisplayKit/ASLayoutController.h>
|
||||
#import <AsyncDisplayKit/ASBaseDefines.h>
|
||||
|
||||
NS_ASSUME_NONNULL_BEGIN
|
||||
|
||||
@interface ASAbstractLayoutController : NSObject <ASLayoutController>
|
||||
|
||||
- (void)setTuningParameters:(ASRangeTuningParameters)tuningParameters forRangeType:(ASLayoutRangeType)rangeType;
|
||||
@ -18,3 +20,5 @@
|
||||
@property (nonatomic, assign) ASRangeTuningParameters tuningParameters ASDISPLAYNODE_DEPRECATED;
|
||||
|
||||
@end
|
||||
|
||||
NS_ASSUME_NONNULL_END
|
||||
|
||||
@ -8,6 +8,7 @@
|
||||
|
||||
#import <AsyncDisplayKit/ASImageProtocols.h>
|
||||
|
||||
NS_ASSUME_NONNULL_BEGIN
|
||||
|
||||
/**
|
||||
* @abstract Simple NSURLSession-based image downloader.
|
||||
@ -15,3 +16,5 @@
|
||||
@interface ASBasicImageDownloader : NSObject <ASImageDownloaderProtocol>
|
||||
|
||||
@end
|
||||
|
||||
NS_ASSUME_NONNULL_END
|
||||
|
||||
@ -8,6 +8,8 @@
|
||||
|
||||
#import <Foundation/Foundation.h>
|
||||
|
||||
NS_ASSUME_NONNULL_BEGIN
|
||||
|
||||
/**
|
||||
* @abstract A context object to notify when batch fetches are finished or cancelled.
|
||||
*/
|
||||
@ -58,3 +60,5 @@
|
||||
- (void)beginBatchFetching;
|
||||
|
||||
@end
|
||||
|
||||
NS_ASSUME_NONNULL_END
|
||||
|
||||
@ -9,6 +9,8 @@
|
||||
#import <AsyncDisplayKit/ASAbstractLayoutController.h>
|
||||
#import <AsyncDisplayKit/ASBaseDefines.h>
|
||||
|
||||
NS_ASSUME_NONNULL_BEGIN
|
||||
|
||||
@class ASCollectionView;
|
||||
|
||||
@interface ASCollectionViewLayoutController : ASAbstractLayoutController
|
||||
@ -16,3 +18,5 @@
|
||||
- (instancetype)initWithCollectionView:(ASCollectionView *)collectionView;
|
||||
|
||||
@end
|
||||
|
||||
NS_ASSUME_NONNULL_END
|
||||
|
||||
@ -11,6 +11,8 @@
|
||||
#import <AsyncDisplayKit/ASDimension.h>
|
||||
#import "ASFlowLayoutController.h"
|
||||
|
||||
NS_ASSUME_NONNULL_BEGIN
|
||||
|
||||
@class ASCellNode;
|
||||
@class ASDataController;
|
||||
|
||||
@ -66,22 +68,22 @@ typedef NSUInteger ASDataControllerAnimationOptions;
|
||||
Called for batch update.
|
||||
*/
|
||||
- (void)dataControllerBeginUpdates:(ASDataController *)dataController;
|
||||
- (void)dataController:(ASDataController *)dataController endUpdatesAnimated:(BOOL)animated completion:(void (^)(BOOL))completion;
|
||||
- (void)dataController:(ASDataController *)dataController endUpdatesAnimated:(BOOL)animated completion:(void (^ _Nullable)(BOOL))completion;
|
||||
|
||||
/**
|
||||
Called for insertion of elements.
|
||||
*/
|
||||
- (void)dataController:(ASDataController *)dataController didInsertNodes:(NSArray *)nodes atIndexPaths:(NSArray *)indexPaths withAnimationOptions:(ASDataControllerAnimationOptions)animationOptions;
|
||||
- (void)dataController:(ASDataController *)dataController didInsertNodes:(NSArray<ASCellNode *> *)nodes atIndexPaths:(NSArray<NSIndexPath *> *)indexPaths withAnimationOptions:(ASDataControllerAnimationOptions)animationOptions;
|
||||
|
||||
/**
|
||||
Called for deletion of elements.
|
||||
*/
|
||||
- (void)dataController:(ASDataController *)dataController didDeleteNodes:(NSArray *)nodes atIndexPaths:(NSArray *)indexPaths withAnimationOptions:(ASDataControllerAnimationOptions)animationOptions;
|
||||
- (void)dataController:(ASDataController *)dataController didDeleteNodes:(NSArray<ASCellNode *> *)nodes atIndexPaths:(NSArray<NSIndexPath *> *)indexPaths withAnimationOptions:(ASDataControllerAnimationOptions)animationOptions;
|
||||
|
||||
/**
|
||||
Called for insertion of sections.
|
||||
*/
|
||||
- (void)dataController:(ASDataController *)dataController didInsertSections:(NSArray *)sections atIndexSet:(NSIndexSet *)indexSet withAnimationOptions:(ASDataControllerAnimationOptions)animationOptions;
|
||||
- (void)dataController:(ASDataController *)dataController didInsertSections:(NSArray<NSArray<ASCellNode *> *> *)sections atIndexSet:(NSIndexSet *)indexSet withAnimationOptions:(ASDataControllerAnimationOptions)animationOptions;
|
||||
|
||||
/**
|
||||
Called for deletion of sections.
|
||||
@ -139,7 +141,7 @@ typedef NSUInteger ASDataControllerAnimationOptions;
|
||||
|
||||
- (void)endUpdates;
|
||||
|
||||
- (void)endUpdatesAnimated:(BOOL)animated completion:(void (^)(BOOL))completion;
|
||||
- (void)endUpdatesAnimated:(BOOL)animated completion:(void (^ _Nullable)(BOOL))completion;
|
||||
|
||||
- (void)insertSections:(NSIndexSet *)sections withAnimationOptions:(ASDataControllerAnimationOptions)animationOptions;
|
||||
|
||||
@ -149,11 +151,11 @@ typedef NSUInteger ASDataControllerAnimationOptions;
|
||||
|
||||
- (void)moveSection:(NSInteger)section toSection:(NSInteger)newSection withAnimationOptions:(ASDataControllerAnimationOptions)animationOptions;
|
||||
|
||||
- (void)insertRowsAtIndexPaths:(NSArray *)indexPaths withAnimationOptions:(ASDataControllerAnimationOptions)animationOptions;
|
||||
- (void)insertRowsAtIndexPaths:(NSArray<NSIndexPath *> *)indexPaths withAnimationOptions:(ASDataControllerAnimationOptions)animationOptions;
|
||||
|
||||
- (void)deleteRowsAtIndexPaths:(NSArray *)indexPaths withAnimationOptions:(ASDataControllerAnimationOptions)animationOptions;
|
||||
- (void)deleteRowsAtIndexPaths:(NSArray<NSIndexPath *> *)indexPaths withAnimationOptions:(ASDataControllerAnimationOptions)animationOptions;
|
||||
|
||||
- (void)reloadRowsAtIndexPaths:(NSArray *)indexPaths withAnimationOptions:(ASDataControllerAnimationOptions)animationOptions;
|
||||
- (void)reloadRowsAtIndexPaths:(NSArray<NSIndexPath *> *)indexPaths withAnimationOptions:(ASDataControllerAnimationOptions)animationOptions;
|
||||
|
||||
/**
|
||||
* Re-measures all loaded nodes. Used to respond to a change in size of the containing view
|
||||
@ -163,7 +165,7 @@ typedef NSUInteger ASDataControllerAnimationOptions;
|
||||
|
||||
- (void)moveRowAtIndexPath:(NSIndexPath *)indexPath toIndexPath:(NSIndexPath *)newIndexPath withAnimationOptions:(ASDataControllerAnimationOptions)animationOptions;
|
||||
|
||||
- (void)reloadDataWithAnimationOptions:(ASDataControllerAnimationOptions)animationOptions completion:(void (^)())completion;
|
||||
- (void)reloadDataWithAnimationOptions:(ASDataControllerAnimationOptions)animationOptions completion:(void (^ _Nullable)())completion;
|
||||
|
||||
/** @name Data Querying */
|
||||
|
||||
@ -171,10 +173,12 @@ typedef NSUInteger ASDataControllerAnimationOptions;
|
||||
|
||||
- (NSUInteger)numberOfRowsInSection:(NSUInteger)section;
|
||||
|
||||
- (ASCellNode *)nodeAtIndexPath:(NSIndexPath *)indexPath;
|
||||
- (nullable ASCellNode *)nodeAtIndexPath:(NSIndexPath *)indexPath;
|
||||
|
||||
- (NSArray *)nodesAtIndexPaths:(NSArray *)indexPaths;
|
||||
- (NSArray<ASCellNode *> *)nodesAtIndexPaths:(NSArray<NSIndexPath *> *)indexPaths;
|
||||
|
||||
- (NSArray *)completedNodes; // This provides efficient access to the entire _completedNodes multidimensional array.
|
||||
- (NSArray<NSArray <ASCellNode *> *> *)completedNodes; // This provides efficient access to the entire _completedNodes multidimensional array.
|
||||
|
||||
@end
|
||||
|
||||
NS_ASSUME_NONNULL_END
|
||||
|
||||
@ -8,6 +8,7 @@
|
||||
|
||||
#import <Foundation/Foundation.h>
|
||||
|
||||
NS_ASSUME_NONNULL_BEGIN
|
||||
|
||||
/**
|
||||
* _OBJC_SUPPORTED_INLINE_REFCNT_WITH_DEALLOC2MAIN permits classes to implement their own reference counting and enforce
|
||||
@ -19,3 +20,5 @@
|
||||
- (BOOL)_isDeallocating;
|
||||
|
||||
@end
|
||||
|
||||
NS_ASSUME_NONNULL_END
|
||||
|
||||
@ -9,6 +9,9 @@
|
||||
#import <AsyncDisplayKit/ASAbstractLayoutController.h>
|
||||
#import <AsyncDisplayKit/ASBaseDefines.h>
|
||||
|
||||
NS_ASSUME_NONNULL_BEGIN
|
||||
|
||||
@class ASCellNode;
|
||||
|
||||
typedef NS_ENUM(NSUInteger, ASFlowLayoutDirection) {
|
||||
ASFlowLayoutDirectionVertical,
|
||||
@ -17,7 +20,7 @@ typedef NS_ENUM(NSUInteger, ASFlowLayoutDirection) {
|
||||
|
||||
@protocol ASFlowLayoutControllerDataSource
|
||||
|
||||
- (NSArray *)completedNodes; // This provides access to ASDataController's _completedNodes multidimensional array.
|
||||
- (NSArray<NSArray <ASCellNode *> *> *)completedNodes; // This provides access to ASDataController's _completedNodes multidimensional array.
|
||||
|
||||
@end
|
||||
|
||||
@ -33,3 +36,5 @@ typedef NS_ENUM(NSUInteger, ASFlowLayoutDirection) {
|
||||
- (instancetype)initWithScrollOption:(ASFlowLayoutDirection)layoutDirection;
|
||||
|
||||
@end
|
||||
|
||||
NS_ASSUME_NONNULL_END
|
||||
|
||||
@ -8,6 +8,7 @@
|
||||
|
||||
#import <QuartzCore/QuartzCore.h>
|
||||
|
||||
NS_ASSUME_NONNULL_BEGIN
|
||||
|
||||
@interface ASHighlightOverlayLayer : CALayer
|
||||
|
||||
@ -19,16 +20,16 @@
|
||||
@param rects Array containing CGRects wrapped in NSValue.
|
||||
@param targetLayer The layer that the rects are relative to. The rects will be translated to the receiver's coordinate space when rendering.
|
||||
*/
|
||||
- (id)initWithRects:(NSArray *)rects targetLayer:(id)targetLayer;
|
||||
- (id)initWithRects:(NSArray<NSValue *> *)rects targetLayer:(nullable CALayer *)targetLayer;
|
||||
|
||||
/**
|
||||
@summary Initializes with CGRects for the highlighting, in the receiver's coordinate space.
|
||||
|
||||
@param rects Array containing CGRects wrapped in NSValue.
|
||||
*/
|
||||
- (id)initWithRects:(NSArray *)rects;
|
||||
- (id)initWithRects:(NSArray<NSValue *> *)rects;
|
||||
|
||||
@property (atomic, strong) __attribute__((NSObject)) CGColorRef highlightColor;
|
||||
@property (nullable, atomic, strong) __attribute__((NSObject)) CGColorRef highlightColor;
|
||||
@property (atomic, weak) CALayer *targetLayer;
|
||||
|
||||
@end
|
||||
@ -42,3 +43,5 @@
|
||||
@property (nonatomic, assign, setter=as_setAllowsHighlightDrawing:) BOOL as_allowsHighlightDrawing;
|
||||
|
||||
@end
|
||||
|
||||
NS_ASSUME_NONNULL_END
|
||||
|
||||
@ -9,6 +9,7 @@
|
||||
#import <CoreGraphics/CoreGraphics.h>
|
||||
#import <Foundation/Foundation.h>
|
||||
|
||||
NS_ASSUME_NONNULL_BEGIN
|
||||
|
||||
@protocol ASImageCacheProtocol <NSObject>
|
||||
|
||||
@ -23,9 +24,9 @@
|
||||
@discussion If `URL` is nil, `completion` will be invoked immediately with a nil image. This method should not block
|
||||
the calling thread as it is likely to be called from the main thread.
|
||||
*/
|
||||
- (void)fetchCachedImageWithURL:(NSURL *)URL
|
||||
callbackQueue:(dispatch_queue_t)callbackQueue
|
||||
completion:(void (^)(CGImageRef imageFromCache))completion;
|
||||
- (void)fetchCachedImageWithURL:(nullable NSURL *)URL
|
||||
callbackQueue:(nullable dispatch_queue_t)callbackQueue
|
||||
completion:(void (^)(CGImageRef _Nullable imageFromCache))completion;
|
||||
|
||||
@end
|
||||
|
||||
@ -48,10 +49,10 @@
|
||||
@result An opaque identifier to be used in canceling the download, via `cancelImageDownloadForIdentifier:`. You must
|
||||
retain the identifier if you wish to use it later.
|
||||
*/
|
||||
- (id)downloadImageWithURL:(NSURL *)URL
|
||||
callbackQueue:(dispatch_queue_t)callbackQueue
|
||||
downloadProgressBlock:(void (^)(CGFloat progress))downloadProgressBlock
|
||||
completion:(void (^)(CGImageRef image, NSError *error))completion;
|
||||
- (id)downloadImageWithURL:(nullable NSURL *)URL
|
||||
callbackQueue:(nullable dispatch_queue_t)callbackQueue
|
||||
downloadProgressBlock:(void (^ _Nullable)(CGFloat progress))downloadProgressBlock
|
||||
completion:(void (^ _Nullable)(CGImageRef image, NSError *error))completion;
|
||||
|
||||
/**
|
||||
@abstract Cancels an image download.
|
||||
@ -59,6 +60,8 @@
|
||||
`downloadImageWithURL:callbackQueue:downloadProgressBlock:completion:`.
|
||||
@discussion This method has no effect if `downloadIdentifier` is nil.
|
||||
*/
|
||||
- (void)cancelImageDownloadForIdentifier:(id)downloadIdentifier;
|
||||
- (void)cancelImageDownloadForIdentifier:(nullable id)downloadIdentifier;
|
||||
|
||||
@end
|
||||
|
||||
NS_ASSUME_NONNULL_END
|
||||
|
||||
@ -19,8 +19,11 @@ typedef struct {
|
||||
ASIndexPath end;
|
||||
} ASIndexPathRange;
|
||||
|
||||
NS_ASSUME_NONNULL_BEGIN
|
||||
|
||||
ASDISPLAYNODE_EXTERN_C_BEGIN
|
||||
|
||||
|
||||
extern ASIndexPath ASIndexPathMake(NSInteger section, NSInteger row);
|
||||
|
||||
extern BOOL ASIndexPathEqualToIndexPath(ASIndexPath first, ASIndexPath second);
|
||||
@ -41,3 +44,5 @@ ASDISPLAYNODE_EXTERN_C_END
|
||||
- (ASIndexPath)ASIndexPathValue;
|
||||
|
||||
@end
|
||||
|
||||
NS_ASSUME_NONNULL_END
|
||||
|
||||
@ -12,6 +12,9 @@
|
||||
#import <AsyncDisplayKit/ASLayoutRangeType.h>
|
||||
#import <AsyncDisplayKit/ASScrollDirection.h>
|
||||
|
||||
NS_ASSUME_NONNULL_BEGIN
|
||||
|
||||
@class ASCellNode;
|
||||
|
||||
typedef struct {
|
||||
CGFloat leadingBufferScreenfuls;
|
||||
@ -27,26 +30,28 @@ typedef struct {
|
||||
*/
|
||||
- (ASRangeTuningParameters)tuningParametersForRangeType:(ASLayoutRangeType)rangeType;
|
||||
|
||||
- (BOOL)shouldUpdateForVisibleIndexPaths:(NSArray *)indexPaths viewportSize:(CGSize)viewportSize rangeType:(ASLayoutRangeType)rangeType;
|
||||
- (BOOL)shouldUpdateForVisibleIndexPaths:(NSArray<NSIndexPath *> *)indexPaths viewportSize:(CGSize)viewportSize rangeType:(ASLayoutRangeType)rangeType;
|
||||
|
||||
- (NSSet *)indexPathsForScrolling:(ASScrollDirection)scrollDirection viewportSize:(CGSize)viewportSize rangeType:(ASLayoutRangeType)rangeType;
|
||||
|
||||
@property (nonatomic, assign) ASRangeTuningParameters tuningParameters ASDISPLAYNODE_DEPRECATED;
|
||||
|
||||
- (BOOL)shouldUpdateForVisibleIndexPath:(NSArray *)indexPath viewportSize:(CGSize)viewportSize ASDISPLAYNODE_DEPRECATED;
|
||||
- (BOOL)shouldUpdateForVisibleIndexPath:(NSIndexPath *)indexPath viewportSize:(CGSize)viewportSize ASDISPLAYNODE_DEPRECATED;
|
||||
|
||||
- (NSSet *)indexPathsForScrolling:(ASScrollDirection)scrollDirection viewportSize:(CGSize)viewportSize ASDISPLAYNODE_DEPRECATED;
|
||||
|
||||
@optional
|
||||
|
||||
- (void)insertNodesAtIndexPaths:(NSArray *)indexPaths withSizes:(NSArray *)nodeSizes;
|
||||
- (void)insertNodesAtIndexPaths:(NSArray<NSIndexPath *> *)indexPaths withSizes:(NSArray<NSValue *> *)nodeSizes;
|
||||
|
||||
- (void)deleteNodesAtIndexPaths:(NSArray *)indexPaths;
|
||||
- (void)deleteNodesAtIndexPaths:(NSArray<NSIndexPath *> *)indexPaths;
|
||||
|
||||
- (void)insertSections:(NSArray *)sections atIndexSet:(NSIndexSet *)indexSet;
|
||||
- (void)insertSections:(NSArray<NSArray <ASCellNode *>*> *)sections atIndexSet:(NSIndexSet *)indexSet;
|
||||
|
||||
- (void)deleteSectionsAtIndexSet:(NSIndexSet *)indexSet;
|
||||
|
||||
- (void)setVisibleNodeIndexPaths:(NSArray *)indexPaths;
|
||||
- (void)setVisibleNodeIndexPaths:(NSArray<NSIndexPath *> *)indexPaths;
|
||||
|
||||
@end
|
||||
|
||||
NS_ASSUME_NONNULL_END
|
||||
|
||||
@ -8,6 +8,7 @@
|
||||
|
||||
#import <Foundation/Foundation.h>
|
||||
|
||||
NS_ASSUME_NONNULL_BEGIN
|
||||
|
||||
/*
|
||||
* Use this class to compose new attributed strings. You may use the normal
|
||||
@ -38,14 +39,14 @@
|
||||
*/
|
||||
@interface ASMutableAttributedStringBuilder : NSMutableAttributedString
|
||||
|
||||
- (instancetype)initWithString:(NSString *)str attributes:(NSDictionary *)attrs;
|
||||
- (instancetype)initWithString:(NSString *)str attributes:(nullable NSDictionary<NSString *, id> *)attrs;
|
||||
- (instancetype)initWithAttributedString:(NSAttributedString *)attrStr;
|
||||
|
||||
- (void)replaceCharactersInRange:(NSRange)range withString:(NSString *)str;
|
||||
- (void)setAttributes:(NSDictionary *)attrs range:(NSRange)range;
|
||||
- (void)setAttributes:(nullable NSDictionary<NSString *, id> *)attrs range:(NSRange)range;
|
||||
|
||||
- (void)addAttribute:(NSString *)name value:(id)value range:(NSRange)range;
|
||||
- (void)addAttributes:(NSDictionary *)attrs range:(NSRange)range;
|
||||
- (void)addAttributes:(NSDictionary<NSString *, id> *)attrs range:(NSRange)range;
|
||||
- (void)removeAttribute:(NSString *)name range:(NSRange)range;
|
||||
|
||||
- (void)replaceCharactersInRange:(NSRange)range withAttributedString:(NSAttributedString *)attrString;
|
||||
@ -57,3 +58,5 @@
|
||||
- (NSMutableAttributedString *)composedAttributedString;
|
||||
|
||||
@end
|
||||
|
||||
NS_ASSUME_NONNULL_END
|
||||
@ -13,6 +13,7 @@
|
||||
#import <AsyncDisplayKit/ASFlowLayoutController.h>
|
||||
#import <AsyncDisplayKit/ASLayoutController.h>
|
||||
|
||||
NS_ASSUME_NONNULL_BEGIN
|
||||
|
||||
@protocol ASRangeControllerDelegate;
|
||||
|
||||
@ -65,7 +66,7 @@
|
||||
*
|
||||
* @returns an array of index paths corresponding to the nodes currently visible onscreen (i.e., the visible range).
|
||||
*/
|
||||
- (NSArray *)rangeControllerVisibleNodeIndexPaths:(ASRangeController *)rangeController;
|
||||
- (NSArray<NSIndexPath *> *)rangeControllerVisibleNodeIndexPaths:(ASRangeController *)rangeController;
|
||||
|
||||
/**
|
||||
* @param rangeController Sender.
|
||||
@ -88,7 +89,7 @@
|
||||
* @param animated NO if all animations are disabled. YES otherwise.
|
||||
* @param completion Completion block.
|
||||
*/
|
||||
- (void)rangeController:(ASRangeController * )rangeController endUpdatesAnimated:(BOOL)animated completion:(void (^)(BOOL))completion;
|
||||
- (void)rangeController:(ASRangeController * )rangeController endUpdatesAnimated:(BOOL)animated completion:(void (^ _Nullable)(BOOL))completion;
|
||||
|
||||
/**
|
||||
* Fetch nodes at specific index paths.
|
||||
@ -97,7 +98,7 @@
|
||||
*
|
||||
* @param indexPaths Index paths.
|
||||
*/
|
||||
- (NSArray *)rangeController:(ASRangeController *)rangeController nodesAtIndexPaths:(NSArray *)indexPaths;
|
||||
- (NSArray<ASCellNode *> *)rangeController:(ASRangeController *)rangeController nodesAtIndexPaths:(NSArray<NSIndexPath *> *)indexPaths;
|
||||
|
||||
/**
|
||||
* Called for nodes insertion.
|
||||
@ -110,7 +111,7 @@
|
||||
*
|
||||
* @param animationOptions Animation options. See ASDataControllerAnimationOptions.
|
||||
*/
|
||||
- (void)rangeController:(ASRangeController *)rangeController didInsertNodes:(NSArray *)nodes atIndexPaths:(NSArray *)indexPaths withAnimationOptions:(ASDataControllerAnimationOptions)animationOptions;
|
||||
- (void)rangeController:(ASRangeController *)rangeController didInsertNodes:(NSArray<ASCellNode *> *)nodes atIndexPaths:(NSArray<NSIndexPath *> *)indexPaths withAnimationOptions:(ASDataControllerAnimationOptions)animationOptions;
|
||||
|
||||
/**
|
||||
* Called for nodes deletion.
|
||||
@ -123,7 +124,7 @@
|
||||
*
|
||||
* @param animationOptions Animation options. See ASDataControllerAnimationOptions.
|
||||
*/
|
||||
- (void)rangeController:(ASRangeController *)rangeController didDeleteNodes:(NSArray *)nodes atIndexPaths:(NSArray *)indexPaths withAnimationOptions:(ASDataControllerAnimationOptions)animationOptions;
|
||||
- (void)rangeController:(ASRangeController *)rangeController didDeleteNodes:(NSArray<ASCellNode *> *)nodes atIndexPaths:(NSArray<NSIndexPath *> *)indexPaths withAnimationOptions:(ASDataControllerAnimationOptions)animationOptions;
|
||||
|
||||
/**
|
||||
* Called for section insertion.
|
||||
@ -148,3 +149,5 @@
|
||||
- (void)rangeController:(ASRangeController *)rangeController didDeleteSectionsAtIndexSet:(NSIndexSet *)indexSet withAnimationOptions:(ASDataControllerAnimationOptions)animationOptions;
|
||||
|
||||
@end
|
||||
|
||||
NS_ASSUME_NONNULL_END
|
||||
@ -10,6 +10,8 @@
|
||||
|
||||
#import <AsyncDisplayKit/ASLayoutRangeType.h>
|
||||
|
||||
NS_ASSUME_NONNULL_BEGIN
|
||||
|
||||
@class ASDisplayNode;
|
||||
|
||||
@protocol ASRangeHandler <NSObject>
|
||||
@ -20,3 +22,5 @@
|
||||
- (void)node:(ASDisplayNode *)node exitedRangeOfType:(ASLayoutRangeType)rangeType;
|
||||
|
||||
@end
|
||||
|
||||
NS_ASSUME_NONNULL_END
|
||||
@ -10,6 +10,10 @@
|
||||
|
||||
#import <AsyncDisplayKit/ASRangeHandler.h>
|
||||
|
||||
NS_ASSUME_NONNULL_BEGIN
|
||||
|
||||
@interface ASRangeHandlerPreload : NSObject <ASRangeHandler>
|
||||
|
||||
@end
|
||||
|
||||
NS_ASSUME_NONNULL_END
|
||||
|
||||
@ -10,6 +10,10 @@
|
||||
|
||||
#import <AsyncDisplayKit/ASRangeHandler.h>
|
||||
|
||||
NS_ASSUME_NONNULL_BEGIN
|
||||
|
||||
@interface ASRangeHandlerRender : NSObject <ASRangeHandler>
|
||||
|
||||
@end
|
||||
|
||||
NS_ASSUME_NONNULL_END
|
||||
|
||||
@ -10,6 +10,8 @@
|
||||
|
||||
#import "ASBaseDefines.h"
|
||||
|
||||
NS_ASSUME_NONNULL_BEGIN
|
||||
|
||||
typedef NS_OPTIONS(NSInteger, ASScrollDirection) {
|
||||
ASScrollDirectionNone = 0,
|
||||
ASScrollDirectionRight = 1 << 0,
|
||||
@ -32,3 +34,5 @@ BOOL ASScrollDirectionContainsUp(ASScrollDirection scrollDirection);
|
||||
BOOL ASScrollDirectionContainsDown(ASScrollDirection scrollDirection);
|
||||
|
||||
ASDISPLAYNODE_EXTERN_C_END
|
||||
|
||||
NS_ASSUME_NONNULL_END
|
||||
|
||||
@ -11,6 +11,7 @@
|
||||
|
||||
#import <AsyncDisplayKit/ASBaseDefines.h>
|
||||
|
||||
NS_ASSUME_NONNULL_BEGIN
|
||||
|
||||
ASDISPLAYNODE_EXTERN_C_BEGIN
|
||||
/**
|
||||
@ -81,3 +82,5 @@ ASDISPLAYNODE_EXTERN_C_END
|
||||
+ (instancetype)paragraphStyleWithCTParagraphStyle:(CTParagraphStyleRef)coreTextParagraphStyle;
|
||||
|
||||
@end
|
||||
|
||||
NS_ASSUME_NONNULL_END
|
||||
|
||||
@ -8,6 +8,7 @@
|
||||
|
||||
#import <UIKit/UIKit.h>
|
||||
|
||||
NS_ASSUME_NONNULL_BEGIN
|
||||
|
||||
typedef void (^as_renderer_index_block_t)(NSUInteger characterIndex,
|
||||
CGRect glyphBoundingRect,
|
||||
@ -46,10 +47,10 @@ typedef NS_ENUM(NSUInteger, ASTextNodeRendererMeasureOption) {
|
||||
@interface ASTextNodeRenderer : NSObject
|
||||
|
||||
- (instancetype)initWithAttributedString:(NSAttributedString *)attributedString
|
||||
truncationString:(NSAttributedString *)truncationString
|
||||
truncationString:(nullable NSAttributedString *)truncationString
|
||||
truncationMode:(NSLineBreakMode)truncationMode
|
||||
maximumLineCount:(NSUInteger)maximumLineCount
|
||||
exclusionPaths:(NSArray *)exclusionPaths
|
||||
exclusionPaths:(nullable NSArray<UIBezierPath *> *)exclusionPaths
|
||||
constrainedSize:(CGSize)constrainedSize;
|
||||
/*
|
||||
* Designated Initializer
|
||||
@ -59,7 +60,7 @@ typedef NS_ENUM(NSUInteger, ASTextNodeRendererMeasureOption) {
|
||||
* so feel free
|
||||
*/
|
||||
- (instancetype)initWithAttributedString:(NSAttributedString *)attributedString
|
||||
truncationString:(NSAttributedString *)truncationString
|
||||
truncationString:(nullable NSAttributedString *)truncationString
|
||||
truncationMode:(NSLineBreakMode)truncationMode
|
||||
maximumLineCount:(NSUInteger)maximumLineCount
|
||||
constrainedSize:(CGSize)constrainedSize;
|
||||
@ -129,7 +130,7 @@ typedef NS_ENUM(NSUInteger, ASTextNodeRendererMeasureOption) {
|
||||
*
|
||||
* Triggers initialization of textkit components, truncation, and sizing.
|
||||
*/
|
||||
- (NSArray *)rectsForTextRange:(NSRange)textRange
|
||||
- (NSArray<NSValue *> *)rectsForTextRange:(NSRange)textRange
|
||||
measureOption:(ASTextNodeRendererMeasureOption)measureOption;
|
||||
|
||||
/*
|
||||
@ -186,3 +187,5 @@ typedef NS_ENUM(NSUInteger, ASTextNodeRendererMeasureOption) {
|
||||
- (NSUInteger)lineCount;
|
||||
|
||||
@end
|
||||
|
||||
NS_ASSUME_NONNULL_END
|
||||
|
||||
@ -9,6 +9,7 @@
|
||||
#import <Foundation/Foundation.h>
|
||||
#import <UIKit/UIKit.h>
|
||||
|
||||
NS_ASSUME_NONNULL_BEGIN
|
||||
|
||||
/**
|
||||
* @abstract Negates/inverts a UIEdgeInsets.
|
||||
@ -67,3 +68,5 @@ static inline UIEdgeInsets ASDNEdgeInsetsInvert(UIEdgeInsets insets)
|
||||
- (void)setShadowInContext:(CGContextRef)context;
|
||||
|
||||
@end
|
||||
|
||||
NS_ASSUME_NONNULL_END
|
||||
|
||||
@ -11,6 +11,7 @@
|
||||
#import <Foundation/Foundation.h>
|
||||
#import <UIKit/UIKit.h>
|
||||
|
||||
NS_ASSUME_NONNULL_BEGIN
|
||||
|
||||
@interface ASTextKitComponents : NSObject
|
||||
|
||||
@ -21,7 +22,7 @@
|
||||
@return An `ASTextKitComponents` containing the created components. The text view component will be nil.
|
||||
@discussion The returned components will be hooked up together, so they are ready for use as a system upon return.
|
||||
*/
|
||||
+ (ASTextKitComponents *)componentsWithAttributedSeedString:(NSAttributedString *)attributedSeedString
|
||||
+ (ASTextKitComponents *)componentsWithAttributedSeedString:(nullable NSAttributedString *)attributedSeedString
|
||||
textContainerSize:(CGSize)textContainerSize;
|
||||
|
||||
/**
|
||||
@ -35,6 +36,8 @@
|
||||
@property (nonatomic, strong, readonly) NSTextStorage *textStorage;
|
||||
@property (nonatomic, strong, readonly) NSTextContainer *textContainer;
|
||||
@property (nonatomic, strong, readonly) NSLayoutManager *layoutManager;
|
||||
@property (nonatomic, strong) UITextView *textView;
|
||||
@property (nullable, nonatomic, strong) UITextView *textView;
|
||||
|
||||
@end
|
||||
|
||||
NS_ASSUME_NONNULL_END
|
||||
|
||||
@ -9,6 +9,7 @@
|
||||
#import <Foundation/Foundation.h>
|
||||
#import <UIKit/NSLayoutManager.h>
|
||||
|
||||
NS_ASSUME_NONNULL_BEGIN
|
||||
|
||||
/**
|
||||
@abstract This class acts as the NSLayoutManagerDelegate for ASTextNode.
|
||||
@ -28,3 +29,5 @@
|
||||
*/
|
||||
|
||||
@end
|
||||
|
||||
NS_ASSUME_NONNULL_END
|
||||
@ -10,9 +10,13 @@
|
||||
|
||||
#import "ASBaseDefines.h"
|
||||
|
||||
NS_ASSUME_NONNULL_BEGIN
|
||||
|
||||
ASDISPLAYNODE_EXTERN_C_BEGIN
|
||||
|
||||
CGRect asdk_CGRectExpandHorizontally(CGRect rect, CGFloat negativeMultiplier, CGFloat positiveMultiplier);
|
||||
CGRect asdk_CGRectExpandVertically(CGRect rect, CGFloat negativeMultiplier, CGFloat positiveMultiplier);
|
||||
|
||||
ASDISPLAYNODE_EXTERN_C_END
|
||||
|
||||
NS_ASSUME_NONNULL_END
|
||||
|
||||
@ -8,6 +8,7 @@
|
||||
|
||||
#import <UIKit/UIKit.h>
|
||||
|
||||
NS_ASSUME_NONNULL_BEGIN
|
||||
|
||||
@interface NSMutableAttributedString (TextKitAdditions)
|
||||
|
||||
@ -20,3 +21,5 @@
|
||||
- (void)attributeTextInRange:(NSRange)range withTextKitParagraphStyle:(NSParagraphStyle *)paragraphStyle;
|
||||
|
||||
@end
|
||||
|
||||
NS_ASSUME_NONNULL_END
|
||||
@ -8,8 +8,12 @@
|
||||
|
||||
#import <UIKit/UIKit.h>
|
||||
|
||||
NS_ASSUME_NONNULL_BEGIN
|
||||
|
||||
@interface UICollectionViewLayout (ASConvenience)
|
||||
|
||||
- (BOOL)asdk_isFlowLayout;
|
||||
|
||||
@end
|
||||
|
||||
NS_ASSUME_NONNULL_END
|
||||
@ -8,6 +8,8 @@
|
||||
|
||||
#import <UIKit/UIKit.h>
|
||||
|
||||
NS_ASSUME_NONNULL_BEGIN
|
||||
|
||||
|
||||
/**
|
||||
These are the properties we support from CALayer (implemented in the pending state)
|
||||
@ -18,7 +20,7 @@
|
||||
@property (nonatomic, assign) CGPoint position;
|
||||
@property (nonatomic, assign) CGFloat zPosition;
|
||||
@property (nonatomic, assign) CGPoint anchorPoint;
|
||||
@property (nonatomic, retain) id contents;
|
||||
@property (nullable, nonatomic, retain) id contents;
|
||||
@property (nonatomic, assign) CGFloat cornerRadius;
|
||||
@property (nonatomic, assign) CGFloat contentsScale;
|
||||
@property (nonatomic, assign) CATransform3D transform;
|
||||
@ -30,9 +32,9 @@
|
||||
@property (nonatomic, assign) CGFloat shadowRadius;
|
||||
@property (nonatomic, assign) CGFloat borderWidth;
|
||||
@property (nonatomic, assign, getter = isOpaque) BOOL opaque;
|
||||
@property (nonatomic, retain) __attribute__((NSObject)) CGColorRef borderColor;
|
||||
@property (nonatomic, copy) NSString *asyncdisplaykit_name;
|
||||
@property (nonatomic, retain) __attribute__((NSObject)) CGColorRef backgroundColor;
|
||||
@property (nullable, nonatomic, retain) __attribute__((NSObject)) CGColorRef borderColor;
|
||||
@property (nullable, nonatomic, copy) NSString *asyncdisplaykit_name;
|
||||
@property (nullable, nonatomic, retain) __attribute__((NSObject)) CGColorRef backgroundColor;
|
||||
@property (nonatomic, assign) BOOL allowsEdgeAntialiasing;
|
||||
@property (nonatomic, assign) unsigned int edgeAntialiasingMask;
|
||||
|
||||
@ -50,7 +52,7 @@
|
||||
@property (nonatomic, getter=isHidden) BOOL hidden;
|
||||
@property (nonatomic, assign) BOOL autoresizesSubviews;
|
||||
@property (nonatomic, assign) UIViewAutoresizing autoresizingMask;
|
||||
@property (nonatomic, retain) UIColor *tintColor;
|
||||
@property (nonatomic, retain, null_resettable) UIColor *tintColor;
|
||||
@property (nonatomic, assign) CGFloat alpha;
|
||||
@property (nonatomic, assign) CGRect bounds;
|
||||
@property (nonatomic, assign) UIViewContentMode contentMode;
|
||||
@ -76,10 +78,12 @@
|
||||
*/
|
||||
|
||||
// Accessibility identification support
|
||||
@property (nonatomic, copy) NSString *accessibilityIdentifier;
|
||||
@property (nullable, nonatomic, copy) NSString *accessibilityIdentifier;
|
||||
|
||||
@end
|
||||
|
||||
@interface CALayer (ASDisplayNodeLayer)
|
||||
@property (atomic, copy) NSString *asyncdisplaykit_name;
|
||||
@property (nullable, atomic, copy) NSString *asyncdisplaykit_name;
|
||||
@end
|
||||
|
||||
NS_ASSUME_NONNULL_END
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user