I am trying to do some AngularJS directive with KineticJS. I want a draggable joystick which is a circle in a kinetic canvas, i now want to add a event listener, which should work for touch and mouse. I started trying touchmove
but that did not work for mouse.
So i took a look at the Object and i realized i can register xChange
and i can do the same for yChange
, but why is there no Listener for a positionChange
? Of course i can register two handlers, but i fear this creates a ton of function calls.
Basically i can use dragmove
since the object is draggable and this function works for both touch and mouse