ios - How to detect a flick gesture using UISwipeGestureRecognizer? -
i heard uiswipegesturerecognizer can used distinguish between slow swipe , fast flick. can't find api tell difference.
do need use uiswipegesturerecognizer
, or can use uipangesturerecognizer
instead? uipangesturerecognizer
gives precise movement data whereas uiswipegesturerecognizer
more basic , detects whether or not swipe happened (and in direction).
uipangesturerecognizer has -velocityinview:
method returns cgpoint, expressing points per second, vertically , horizontally.
Comments
Post a Comment