iOS: fix tableview blink when reload on some devices

This commit is contained in:
王劲鹏 2021-03-09 16:00:55 +08:00 committed by osborn
parent 1a84a3d7bb
commit bd0f155360

View File

@ -77,6 +77,7 @@ - (UITableView *)build {
it.delegate = self; it.delegate = self;
it.separatorStyle = UITableViewCellSeparatorStyleNone; it.separatorStyle = UITableViewCellSeparatorStyleNone;
it.allowsSelection = NO; it.allowsSelection = NO;
it.estimatedRowHeight = 0; // avoid reload data blink
if (@available(iOS 11, *)) { if (@available(iOS 11, *)) {
it.contentInsetAdjustmentBehavior = UIScrollViewContentInsetAdjustmentNever; it.contentInsetAdjustmentBehavior = UIScrollViewContentInsetAdjustmentNever;
} }