iOS 7 UIRefreshControl tintColor not working for beginRefreshing

前端 未结 19 1705
我在风中等你
我在风中等你 2020-12-04 13:48

I\'m trying to set a tintColor on my UIRefreshControl (building on iOS 7). I enabled refreshing for the tableViewController in storyboard, then in my ViewController vi

19条回答
  •  予麋鹿
    予麋鹿 (楼主)
    2020-12-04 14:27

    Set manually content offset for your tableView/scrollView before begin spinning:

    tableView.setContentOffset(CGPoint(x: 0, y: tableView.contentOffset.y - (refreshControl.frame.size.height)), animated: true)
    refreshControl.beginRefreshing()
    ......
    

提交回复
热议问题