iOS 10.0 UIRefreshControl not showing indicator

前端 未结 8 1355
庸人自扰
庸人自扰 2020-12-29 06:02

I am using a UITableView Which has a Pull down to refresh function but the spinner for pull down to refresh is not showing up when I call the [self.refreshControl beginRefre

8条回答
  •  伪装坚强ぢ
    2020-12-29 06:46

    You need to call [self.view layoutIfNeeded] to fix it in iOS 10. For my case it was enough to put the call to viewDidLoad (I was using storyboard in that project). For other cases viewWillAppear fits better.

    - (void)viewDidLoad
      {
       [super viewDidLoad];
       [self.view layoutIfNeeded];
       ...
    

提交回复
热议问题