是否有用于iPhone开发的高级手势库? [英] Is there a high-level gestures library for iPhone development?

查看:153
本文介绍了是否有用于iPhone开发的高级手势库?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

iPhone平台有许多常见的手势习语。例如,存在分接头,夹点和滑动,每个具有不同数量的手指。但是当你开发一个应用程序时,你需要根据关于触摸的数量和位置的低级信息来实现这些事情。似乎这是一个图书馆的首选候选人。您可以注册一个委托,设置一些参数,如多次点击间隔和滑动阈值,并获得像swipeStarted / Ended,pinchStarted / Ended,multiTap等调用。这样的库存在吗?

The iPhone platform has a number of common gesture idioms. For example, there are taps, pinches, and swipes, each with varying number of fingers. But when you're developing an app, it's up to you to implement these things based on low-level information about the number and locations of touches. It seems like this is a prime candidate for a library. You would register a delegate, set some parameters like multi-tap interval and swipe threshold, and get calls like swipeStarted/Ended, pinchStarted/Ended, multiTap, etc. Does such a library exist?

推荐答案

我已经设置了这样一个项目。

I've set up just such a project. It's not a library, but it is full of sample code for pinch/stretch, tap and hold, etc.

博客:

http://6tringle.com/blog/2009/TouchSampleCode.html

Github:

http://github.com/kailoa/6tringle-touchsamplecode/tree/master

这篇关于是否有用于iPhone开发的高级手势库?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆