How can I detect a double tap on a certain cell in UITableView?

后端 未结 14 1040
悲哀的现实
悲哀的现实 2020-12-01 00:18

How can I detect a double tap on a certain cell in UITableView?

i.e. I want to perform one action if the user made a single touch and a

14条回答
  •  天命终不由人
    2020-12-01 00:51

    You'll probably need to subclass UITableView and override whatever touch events are appropriate (touchesBegan:withEvent;, touchesEnded:withEvent, etc.) Inspect the events to see how many touches there were, and do your custom behavior. Don't forget to call through to UITableView's touch methods, or else you won't get the default behavior.

提交回复
热议问题