fljot / Gestouch

Gestouch: multitouch gesture recognition library for Flash (ActionScript) development.
MIT License
356 stars 84 forks source link

PanGesture minNumTouchesRequired & maxNumTouchesRequired? #5

Closed mrbbp closed 12 years ago

mrbbp commented 12 years ago

var panA2D:PanGesture = new PanGesture(stage); panA2D.addEventListener(PanGestureEvent.GESTURE_PAN, onPanSequence); panA2D.minNumTouchesRequired = 2; panA2D.maxNumTouchesRequired = 2;

the listener fire with 1 and 2 touchs ?

where am i wrong ? regards

fljot commented 12 years ago

Haven't you got Error when setting minNumTouchesRequired = 2 before setting maxNumTouchesRequired = 2? According to the code (I can't test it right now) it should throw ArgumentError if you're trying to set minNumTouchesRequired to a greater value than current maxNumTouchesRequired (this is for a safety reason not to accidentally set min > max). So you should set max before min, hope would work as expected.

mrbbp commented 12 years ago

Sorry i test and play (as naughty graphic designer) in Flash pro (CS6) directly on my device... silent error (i don't know how to debug "online") For me, it was making sens to init the min before the max... But it was not ;(

mrbbp commented 12 years ago

ohhh it's ok now. Thanks very much.