开发者

How to determine if scrolling a UITableView was done by tapping the index?

开发者 https://www.devze.com 2022-12-11 07:16 出处:网络
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

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.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号