RotateGesture fix

I have no idea why I put that condition before, but obviously I expect to have -1 rotation instead of 359.
This commit is contained in:
Pavel fljot 2011-08-17 14:04:29 +03:00
parent d65cf3ac90
commit 5b0ae2ef00

View file

@ -108,10 +108,6 @@ package org.gestouch.gestures
var a1:Number = Math.atan2(_lastVector.y, _lastVector.x);
var a2:Number = Math.atan2(_currVector.y, _currVector.x);
var angle:Number = a2 - a1;
if (angle < 0)
{
angle += GestureUtils.PI_DOUBLE;
}
angle *= GestureUtils.RADIANS_TO_DEGREES;
_dispatch(new RotateGestureEvent(RotateGestureEvent.GESTURE_ROTATE, true, false, GesturePhase.UPDATE, _lastLocalCentralPoint.x, _lastLocalCentralPoint.y, 1, 1, angle));