mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-12-24 07:05:35 +00:00
Merge pull request #1867 from maicki/MSFixXcode8Errors
Fix Xcode 8 Errors
This commit is contained in:
@@ -39,6 +39,10 @@ NSInteger const ASDefaultDrawingPriority = ASDefaultTransactionPriority;
|
||||
NSString * const ASRenderingEngineDidDisplayScheduledNodesNotification = @"ASRenderingEngineDidDisplayScheduledNodes";
|
||||
NSString * const ASRenderingEngineDidDisplayNodesScheduledBeforeTimestamp = @"ASRenderingEngineDidDisplayNodesScheduledBeforeTimestamp";
|
||||
|
||||
// Forward declare CALayerDelegate protocol as the iOS 10 SDK moves CALayerDelegate from a formal delegate to a protocol.
|
||||
// We have to forward declare the protocol as this place otherwise it will not compile compiling with an Base SDK < iOS 10
|
||||
@protocol CALayerDelegate;
|
||||
|
||||
@interface ASDisplayNode () <UIGestureRecognizerDelegate, _ASDisplayLayerDelegate, _ASTransitionContextCompletionDelegate>
|
||||
|
||||
/**
|
||||
@@ -493,7 +497,8 @@ static ASDisplayNodeMethodOverrides GetASDisplayNodeMethodOverrides(Class c)
|
||||
if (isLayerBacked) {
|
||||
TIME_SCOPED(_debugTimeToCreateView);
|
||||
_layer = [self _layerToLoad];
|
||||
_layer.delegate = self;
|
||||
// Surpress warning for Base SDK > 10.0
|
||||
_layer.delegate = (id<CALayerDelegate>)self;
|
||||
} else {
|
||||
TIME_SCOPED(_debugTimeToCreateView);
|
||||
_view = [self _viewToLoad];
|
||||
|
||||
Reference in New Issue
Block a user