开发者

How can I set a UITapGestureRecognizer's timeout threshold?

开发者 https://www.devze.com 2023-03-14 22:07 出处:网络
I\'m using a UITapGestureRecognizer in my iPad app and I want to change the duration it inter开发者_Python百科prets as being short enough for a tap. I want my tap to be recognised on finger-up however

I'm using a UITapGestureRecognizer in my iPad app and I want to change the duration it inter开发者_Python百科prets as being short enough for a tap. I want my tap to be recognised on finger-up however long I hold down my finger. How can I achieve this?


I don't believe you can override the gesture duration the way you want to. However you can use UILongPressGestureRecognizer, which does exactly what you seem to need.

0

精彩评论

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