美文网首页
swift 隐藏多余的TableView

swift 隐藏多余的TableView

作者: Antlers777 | 来源:发表于2020-05-26 15:15 被阅读0次

//  消除 多余 cell

    override func tableView(_tableView:UITableView, viewForFooterInSection section:Int) ->UIView? {

        if(section == tableView.numberOfSections-1){

            return UIView.init(frame:CGRect(x:0, y:0,width:1, height:1))

        }

        return nil

    }

或者

tableView?.tableFooterView = .init()

相关文章

网友评论

      本文标题:swift 隐藏多余的TableView

      本文链接:https://www.haomeiwen.com/subject/sjqvahtx.html