onMove(...)

Hi,



I add a MouseInputListener to capture mouse position when it moves. Right now the onMove(…) function is only called when the mouse is pressed and moves.

How can i capture the mouse movement without the need to be pressed?



Thanks.

Have you tried Sellotape?

MouseInput.get().addListener( new MouseMouseInputListener() {

Not, i get the same result.

Can you make demo code available that shows the behavior?

    public void simpleAppletSetup()

    {

          MouseInput.get().addListener(this);

    }



        public void onMove(int xDelta, int yDelta, int newX, int newY)

{

System.out.println("we are moving");

}

Ok… I think I worked it out for you:



Add this to your setup:



((AWTMouseInput) MouseInput.get()).setDragOnly(false);



The dragOnly setting of AWTMouseInput is being defaulted to true.



This keeps the mouseMoved event from being processed.


it rocks!



Thanks.