public class DragListener
extends javax.swing.event.MouseInputAdapter
This class provides drag functionality for a component. It’s used to make table string filter layers draggable.
Modifier and Type | Field and Description |
---|---|
(package private) java.awt.event.MouseEvent |
dragStart |
(package private) java.awt.Point |
location |
Constructor and Description |
---|
DragListener() |
Modifier and Type | Method and Description |
---|---|
void |
mouseDragged(java.awt.event.MouseEvent e)
Moves the component to the new location.
|
void |
mousePressed(java.awt.event.MouseEvent e)
Remembers the starting point of the dragging.
|
mouseClicked, mouseEntered, mouseExited, mouseMoved, mouseReleased, mouseWheelMoved
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
public void mousePressed(java.awt.event.MouseEvent e)
Remembers the starting point of the dragging.
mousePressed
in interface java.awt.event.MouseListener
mousePressed
in class java.awt.event.MouseAdapter
e
- the mouse eventpublic void mouseDragged(java.awt.event.MouseEvent e)
Moves the component to the new location.
mouseDragged
in interface java.awt.event.MouseMotionListener
mouseDragged
in class java.awt.event.MouseAdapter
e
- the mouse event