mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-12-22 22:25:57 +00:00
iOS 11 UITableView automatic height estimation fix (#485)
* Add iOS 11 checks. * Negate iOS 11 automatic table height estimatation * Negate iOS 11 automatic estimated table row heights * Add note about iOS 11 estimated height behavior
This commit is contained in:
committed by
Huy Nguyen
parent
3c6b836571
commit
10efa31abd
@@ -345,6 +345,13 @@ static NSString * const kCellReuseIdentifier = @"_ASTableViewCell";
|
||||
_retainedLayer = self.layer;
|
||||
}
|
||||
|
||||
// iOS 11 automatically uses estimated heights, so disable those (see PR #485)
|
||||
if (AS_AT_LEAST_IOS11) {
|
||||
super.estimatedRowHeight = 0.0;
|
||||
super.estimatedSectionHeaderHeight = 0.0;
|
||||
super.estimatedSectionFooterHeight = 0.0;
|
||||
}
|
||||
|
||||
return self;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user