Monthly Archives: January 2010
Actionscript 3: Detect the difference between a Mouse click and a Mouse drag.
How do you tell if the user clicked or dragged in your flash app? Take a look: private var time:uint; function onMouseDown(event:Event):void { time = getTimer(); startDrag(); } function onMouseUp(event:Event):void { var diff = getTimer() – time; if (diff < … Continue reading