7

I used to have a UITableView in a UIViewController. I would put a UIRefreshControl on the UITableView and on the very last bit of swiping down to refresh, the UITableView would quickly jump down.

All answers voiced the same: Undocumented/unexpected behavior (being able to use UIRefreshControl with a UITableView) yields such results. To mitigate this, I used a ContainerView to embed a UITableViewController in a UIViewController.

I have nearly solved this issue, but... if I swipe down slow enough, the problem persists.

Is there any way to mitigate this, or am I forced to live with it?

Video: http://streamable.com/8suq

Notice the first few times I swipe down look absolutely fine because I do it fast enough, but towards the end of the video I really slow it down and you notice the jump in question.

David
  • 7,028
  • 10
  • 48
  • 95

1 Answers1

2

I notice that you have a mouse cursor in that video. You cannot judge graphic performance for animations in the simulator, it will not perform the same as on an actual device.

On a device you will get much better performance and a much better frames per second rate. I've seen this to be very noticable when using SpriteKit whilst learning to develop games lately.

I've only used the UIRefreshControl a couple of times previously in a UITableViewController and not noticed any major issues before. Since then I've been using other libraries such as https://github.com/samvermette/SVPullToRefresh.

Try your app on a physical device and in the meantime I will try to replicate your issue and add my findings in here

Scriptable
  • 19,402
  • 5
  • 56
  • 72
  • I actually ran into this on a device and used the simulator so I could record it happening to put on here. I've since fixed it and learned how to record my actual screen so I no longer use the simulator. This was a while back, so I don't remember my fix. – David Mar 08 '17 at 23:33
  • @David, if you've fixed it, could you share your knowledge? It seems that others have this issue as well (judging by the bounty added to this question) – SergGr Mar 08 '17 at 23:51