Package uk.ac.starlink.util.gui
Class DragListener
java.lang.Object
java.awt.event.MouseAdapter
javax.swing.event.MouseInputAdapter
uk.ac.starlink.util.gui.DragListener
- All Implemented Interfaces:
MouseListener
,MouseMotionListener
,MouseWheelListener
,EventListener
,MouseInputListener
Mouse listener object which watches for a drag gesture, and invokes
TransferHandler.exportAsDrag() when it sees one.
Note this must be installed as
both a
MouseListener
and a MouseMotionListener
on the component it's watching.- Author:
- Mark Taylor (Starlink)
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
mouseDragged
(MouseEvent evt) void
mouseEntered
(MouseEvent evt) void
mousePressed
(MouseEvent evt) void
mouseReleased
(MouseEvent evt) Methods inherited from class java.awt.event.MouseAdapter
mouseClicked, mouseExited, mouseMoved, mouseWheelMoved
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface java.awt.event.MouseListener
mouseClicked, mouseExited
Methods inherited from interface java.awt.event.MouseMotionListener
mouseMoved
-
Constructor Details
-
DragListener
public DragListener()
-
-
Method Details
-
mousePressed
- Specified by:
mousePressed
in interfaceMouseListener
- Overrides:
mousePressed
in classMouseAdapter
-
mouseReleased
- Specified by:
mouseReleased
in interfaceMouseListener
- Overrides:
mouseReleased
in classMouseAdapter
-
mouseEntered
- Specified by:
mouseEntered
in interfaceMouseListener
- Overrides:
mouseEntered
in classMouseAdapter
-
mouseDragged
- Specified by:
mouseDragged
in interfaceMouseMotionListener
- Overrides:
mouseDragged
in classMouseAdapter
-