开发者

UISwipeGestureRecognizer Swipe Distance

Any idea if ther开发者_JAVA技巧e is a simple way to lengthen the distance a swipe has to travel before being recognized. Seems the the default is really short. It's more than a tap, but just barely. Do I need to create a custom gesture recognizer to override this distance?

Thanks.


Having no documented properties to set that means there're no documented properties to set that. You can create your own gesture recognizer, though.


There are 7 undocumented properties to change the default behavior:

@interface UISwipeGestureRecognizer()
@property(assign, nonatomic) CGFloat minimumPrimaryMovement;
@property(assign, nonatomic) CGFloat maximumPrimaryMovement;
@property(assign, nonatomic) CGFloat minimumSecondaryMovement;
@property(assign, nonatomic) CGFloat maximumSecondaryMovement;
@property(assign, nonatomic) NSTimeInterval maximumDuration;
@property(assign, nonatomic) float rateOfMinimumMovementDecay;
@property(assign, nonatomic) float rateOfMaximumMovementDecay;
@end

but if you write for AppStore you can't use these.

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜