mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-12-23 14:45:21 +00:00
Don't set cell node frames during measurement
This commit is contained in:
@@ -108,7 +108,6 @@ static void *kASSizingQueueContext = &kASSizingQueueContext;
|
|||||||
if (node.isNodeLoaded && node.needsMeasure) {
|
if (node.isNodeLoaded && node.needsMeasure) {
|
||||||
ASSizeRange constrainedSize = [_dataSource dataController:self constrainedSizeForNodeAtIndexPath:indexPath];
|
ASSizeRange constrainedSize = [_dataSource dataController:self constrainedSizeForNodeAtIndexPath:indexPath];
|
||||||
[node measureWithSizeRange:constrainedSize];
|
[node measureWithSizeRange:constrainedSize];
|
||||||
node.frame = CGRectMake(0, 0, node.calculatedSize.width, node.calculatedSize.height);
|
|
||||||
node.needsMeasure = NO;
|
node.needsMeasure = NO;
|
||||||
}
|
}
|
||||||
}];
|
}];
|
||||||
@@ -138,7 +137,6 @@ static void *kASSizingQueueContext = &kASSizingQueueContext;
|
|||||||
// Nodes with main thread affinity should all have already been measured.
|
// Nodes with main thread affinity should all have already been measured.
|
||||||
if (node.needsMeasure) {
|
if (node.needsMeasure) {
|
||||||
[node measureWithSizeRange:constrainedSize];
|
[node measureWithSizeRange:constrainedSize];
|
||||||
node.frame = CGRectMake(0, 0, node.calculatedSize.width, node.calculatedSize.height);
|
|
||||||
node.needsMeasure = NO;
|
node.needsMeasure = NO;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user