获取iPhone应用中的滑动动作的时间跨度(get timespan of swipe action in iPhone app)

编程入门 行业动态 更新时间:2024-10-21 03:44:16
获取iPhone应用中的滑动动作的时间跨度(get timespan of swipe action in iPhone app)

我们如何才能获得用户完成向右滑动或向左滑动操作所花费的时间? 已经谷歌但没有运气。 如果没有内置解决方案,将触摸开始和触摸结束一起工作?

How can we get the time a user spent to finish a swipe right or swipe left action? Already googled but no luck. If there is not built-in solution already, will touch begin and touch end together work?

最满意答案

测量开始和结束时间,并计算在gestureRecognizer.state == UIGestureRecognizerStateBegan和gestureRecognizer.state == UIGestureRecognizerStateEnded的UIGestureRecognizer回调方法中的gestureRecognizer.state == UIGestureRecognizerStateBegan

Measure the start and end time, and calculate the difference in the UIGestureRecognizer callback method for gestureRecognizer.state == UIGestureRecognizerStateBegan and gestureRecognizer.state == UIGestureRecognizerStateEnded

更多推荐

本文发布于:2023-08-04 22:17:00,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1424533.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:跨度   动作   时间   iPhone   app

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!