UITableView 当cell的数量不能占满屏幕时 如何在TableFooterView上显示出直达底部的线来

UIView *backgroundView = [[UIView alloc] initWithFrame:CGRectMake(0, 0, 100, 100)];

    backgroundView.backgroundColor = [UIColor clearColor];

    UIView *timeVLine = [[UIView alloc] initWithFrame:CGRectMake(33, 0, 0.4, 100)];

    [backgroundView addSubview:timeVLine];

    timeVLine.backgroundColor = [UIColor redColor];

    timeVLine.autoresizingMask = UIViewAutoresizingFlexibleHeight;

    tableView.backgroundView = backgroundView;

注意:backgroundViewtimeVLine等高

猜你喜欢

转载自blog.csdn.net/allanGold/article/details/86310471