I'm trying to limit the scroll speed of my UITableView, exactly like Instagram does it.
If you check out Instagram, you'll notice that they have a limit on how fast you can scroll through the feed.
It's not set using "decelerationRate" since the limit doesn't affect the deceleration. It simply affects the how fast you can scroll through the feed. So if you try to do a "flick" gesture, you will hit Instagrams max scrolling speed and won't go as fast as in a normal UITableView.
Any guesses on how Instagram accomplishes this?
TableView has a property
scrollView
, This property will return internal scrollView of TableView. Use following...ANOTHER WAY:
TableView will respond to scrollView delegate, so we need to implement scrollView's delegate like:
Take these global variables :
Implement
scrollViewDidScroll
like :Then implement
scrollViewDidEndDragging
like this :Hope this may help you...