动态设置TableView加载完毕后TableView的高度

来源:互联网 发布:学日语 知乎 编辑:程序博客网 时间:2024/05/22 19:00
    // 动态设置TableView加载完毕后TableView的高度    if(indexPath.row == ((NSIndexPath *)[[tableView indexPathsForVisibleRows] lastObject]).row) {        //end of loading        dispatch_async(dispatch_get_main_queue(), ^{            self.tableView.frame = CGRectMake(self.tableView.frame.origin.x, self.tableView.frame.origin.y, SCREEN_WIDTH, tableView.contentSize.height);        });    }
原创粉丝点击