mouseDragged
mouseDragged is an event-handling method in Java's AWT/Swing event model. It is defined by the MouseMotionListener interface and is invoked when the user moves the mouse while a button is pressed, i.e., during a drag, over a component that has registered the listener.
During a dragging operation, a component receives successive MouseEvent objects via mouseDragged, each describing the cursor
mouseDragged is distinct from mouseMoved, which is fired when the mouse moves with no button pressed. A
Common uses include implementing drag-and-drop-like interactions, interactive drawing, or object manipulation within a GUI. In code,
Notes: the handler is called repeatedly as the cursor moves, so long-running work should not block the