mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-12-22 22:25:57 +00:00
Introduce ASIndexedNodeContext
- It is a container object that holds enough information to construct and measure a cell node - All information is gathered on main thread. This allows ASDataController to capture the correct state of its data source before going to background.
This commit is contained in:
22
AsyncDisplayKit/Details/ASIndexedNodeContext.h
Normal file
22
AsyncDisplayKit/Details/ASIndexedNodeContext.h
Normal file
@@ -0,0 +1,22 @@
|
||||
//
|
||||
// ASIndexedNodeContext.h
|
||||
// AsyncDisplayKit
|
||||
//
|
||||
// Created by Huy Nguyen on 2/28/16.
|
||||
// Copyright © 2016 Facebook. All rights reserved.
|
||||
//
|
||||
|
||||
#import <AsyncDisplayKit/ASDataController.h>
|
||||
#import <AsyncDisplayKit/ASDimension.h>
|
||||
|
||||
@interface ASIndexedNodeContext : NSObject
|
||||
|
||||
@property (nonatomic, readonly, strong) ASCellNodeBlock nodeBlock;
|
||||
@property (nonatomic, readonly, assign) NSIndexPath *indexPath;
|
||||
@property (nonatomic, readonly, assign) ASSizeRange constrainedSize;
|
||||
|
||||
- (instancetype)initWithNodeBlock:(ASCellNodeBlock)nodeBlock
|
||||
indexPath:(NSIndexPath *)indexPath
|
||||
constrainedSize:(ASSizeRange)constrainedSize;
|
||||
|
||||
@end
|
||||
Reference in New Issue
Block a user