# 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`

public class DragListener extends MouseInputAdapter
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
Constructor
Description
`DragListener()`

## Method Summary

Modifier and Type
Method
Description
`void`
`mouseDragged(MouseEvent evt)`
`void`
`mouseEntered(MouseEvent evt)`
`void`
`mousePressed(MouseEvent evt)`
`void`
`mouseReleased(MouseEvent evt)`

### Methods inherited from class MouseAdapter

`mouseClicked, mouseExited, mouseMoved, mouseWheelMoved`

### Methods inherited from class Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Methods inherited from interface MouseListener

`mouseClicked, mouseExited`

### Methods inherited from interface MouseMotionListener

`mouseMoved`

## Constructor Details

### DragListener

public DragListener()

## Method Details

### mousePressed

public void mousePressed(MouseEvent evt)

Specified by:
  `mousePressed` in interface `MouseListener`
Overrides:
  `mousePressed` in class `MouseAdapter`

### mouseReleased

public void mouseReleased(MouseEvent evt)

Specified by:
  `mouseReleased` in interface `MouseListener`
Overrides:
  `mouseReleased` in class `MouseAdapter`

### mouseEntered

public void mouseEntered(MouseEvent evt)

Specified by:
  `mouseEntered` in interface `MouseListener`
Overrides:
  `mouseEntered` in class `MouseAdapter`

### mouseDragged

public void mouseDragged(MouseEvent evt)

Specified by:
  `mouseDragged` in interface `MouseMotionListener`
Overrides:
  `mouseDragged` in class `MouseAdapter`