- - (CGFloat)tableView:(UITableView *)tableView heightForRowAtIndexPath:(NSIndexPath *)indexPath
- {
- GYActivityCenterCell *cell = (GYActivityCenterCell *)[tableView dequeueReusableCellWithIdentifier:cellIntifier];
- GYActivityCenterModel *model = dataSourceArray[indexPath.row];
- [cell setContentWithModel:model andPicSavePath:activityCenterModelLsit.savePath]; ///这里是设置填充内容到cell中.
- [cell layoutIfNeeded];
- CGFloat height = [cell systemLayoutSizeFittingSize:UILayoutFittingCompressedSize].height;///这里就得到cell的实际高度.
- return height;
- }
tablview高度计算
最新推荐文章于 2021-12-29 09:42:32 发布