mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-12-24 07:05:35 +00:00
ASViewController example improvements (#2592)
This commit is contained in:
committed by
appleguy
parent
171cc2f527
commit
2ba8239ff5
@@ -27,9 +27,10 @@
|
||||
self = [super init];
|
||||
if (self == nil) { return self; }
|
||||
|
||||
self.automaticallyManagesSubnodes = YES;
|
||||
|
||||
_imageNode = [[ASNetworkImageNode alloc] init];
|
||||
_imageNode.backgroundColor = ASDisplayNodeDefaultPlaceholderColor();
|
||||
[self addSubnode:_imageNode];
|
||||
|
||||
return self;
|
||||
}
|
||||
@@ -38,7 +39,7 @@
|
||||
|
||||
- (ASLayoutSpec *)layoutSpecThatFits:(ASSizeRange)constrainedSize
|
||||
{
|
||||
return [ASRatioLayoutSpec ratioLayoutSpecWithRatio:1.0 child:_imageNode];
|
||||
return [ASRatioLayoutSpec ratioLayoutSpecWithRatio:1.0 child:self.imageNode];
|
||||
}
|
||||
|
||||
- (void)layoutDidFinish
|
||||
|
||||
Reference in New Issue
Block a user