fljot / Gestouch

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

Applying Gestouch in Flash movie with MAC touchpad #24

Closed windqofsniper closed 11 years ago

windqofsniper commented 11 years ago

Hi, I would like to know if anyone has tried to use the Gestouch Event within a flash movie and trigger the multitouch event with MAC touchpad. I am a newbie to both flash and Gestouch. And I follow the tutorial to add the TapEvent to my flash movie and it works fine. But when I try to add the FreeTransform Event to my object in the movie like below:

var freeTransform:TransformGesture = new TransformGesture(myImage); freeTransform.addEventListener(GestureEvent.GESTURE_BEGAN, onFreeTransform); freeTransform.addEventListener(GestureEvent.GESTURE_CHANGED, onFreeTransform); ... private function onFreeTransform(event:GestureEvent):void { // move, rotate, scale — all at once for better performance! trace(freeTransform.offsetX, freeTransform.offsetY, freeTransform.rotation, freeTransform.scale); }

The FreeTransform event only trigger when I press down the left button of my MAC touchpad instead of just a tap. And I try to do the rotate and zoom gesture, the rotation and scale value are always 0 and 1 respectively. Anyone know why it would happened? Am I miss something in the configuration?

Thank for help!

fljot commented 11 years ago

Even though Mac's touchpad is known as "multitouch", it (and OS X) do not provide flash runtime with distinctive touch points.

windqofsniper commented 11 years ago

So I can't test the multitouch event in Mac's touchpad right? I can only build the app and test it in other multitouch device like tablet, right?

fljot commented 11 years ago

Normally yes. Alternatively you could write multitouch simulator.