How to determine if scrolling a UITableView was done by tapping the index?
I want to determine when the index (transparent alphabet) along the side of a UITableView
is tapped. To be more specific, I have a sectioned UITableView
that has an index, and said index does the right thing, but开发者_高级运维 when the UITableView's
-scrollViewDidScroll
method is called, I want to be able to determine if said scrolling was the result of the user tapping the index, vs. dragging or swiping the table view itself. If anyone has ideas on how to do this, i'd love to hear about them :-)
Regards,
John
You could override touchesBegan to monitor the location of any touch event that precedes scrollViewDidScroll.
精彩评论