We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
在iOS11上面, 进入聊天界面发现,Cell不能滚动到最新的一行Cell,
具体代码: if (self.dataSource.count > 0) { [self.tableView scrollToRowAtIndexPath:[NSIndexPath indexPathForRow:self.dataSource.count-1 inSection:0] atScrollPosition:UITableViewScrollPositionBottom animated:NO]; }
可以帮忙看一下嘛。 楼主。
The text was updated successfully, but these errors were encountered:
如果你用autolayout,就可以解决这个问题
Sorry, something went wrong.
已经解决了, 在new _tableView的时候加上下面的代码. iOS11新出来的坑..记录一下 /*Self-Sizing在iOS11下是默认开启的,Headers, footers, and cells都默认开启Self-Sizing,所有estimated 高度默认值从iOS11之前的 0 改变为UITableViewAutomaticDimension: 解决iOS11 uitableview不能滑动到最后一行的bug */ _tableView.estimatedRowHeight = 0; _tableView.estimatedSectionHeaderHeight = 0; _tableView.estimatedSectionFooterHeight = 0;
No branches or pull requests
在iOS11上面, 进入聊天界面发现,Cell不能滚动到最新的一行Cell,
具体代码:
if (self.dataSource.count > 0) {
[self.tableView scrollToRowAtIndexPath:[NSIndexPath indexPathForRow:self.dataSource.count-1 inSection:0] atScrollPosition:UITableViewScrollPositionBottom animated:NO];
}
可以帮忙看一下嘛。 楼主。
The text was updated successfully, but these errors were encountered: