How Do I Shorten the Pull Distance on UIRefreshControl to Activate the Pull to Refresh Action?

后端 未结 5 1122
傲寒
傲寒 2021-02-07 09:27

Hey StackOverflow People,

I\'ve been trying to figure out this question for some time now but to no avail and I need some help. I have a UITableView close t

5条回答
  •  暗喜
    暗喜 (楼主)
    2021-02-07 10:03

    One line code

    The value for that is _snappingHeight and you can set it to what ever you need like:

    refreshControl.setValue(100, forKey: "_snappingHeight")
    

    Note that this is a private API and although it’s tested on the appstore, it may reject in the future.

提交回复
热议问题