public class MultiDropTarget extends DropTarget
MultiDropTarget is associated with a Component
when that Component wishes to accept drops during Drag and
Drop operations.
Each DropTarget is associated with a FlavorMap.
The default FlavorMap hereafter designates the
FlavorMap returned by
SystemFlavorMap.getDefaultFlavorMap().
DropTarget.DropTargetAutoScroller| Constructor and Description |
|---|
MultiDropTarget(Component c,
int ops,
DropTargetListener dtl)
Creates a
MultiDropTarget given the Component
to associate itself with, an int representing the default
acceptable action(s) to support, and a DropTargetListener
to handle event processing. |
| Modifier and Type | Method and Description |
|---|---|
void |
addDropTargetListener(DropTargetListener dtl) |
void |
dragEnter(DropTargetDragEvent e) |
void |
dragExit(DropTargetEvent e) |
void |
dragOver(DropTargetDragEvent e) |
void |
drop(DropTargetDropEvent e) |
void |
dropActionChanged(DropTargetDragEvent e) |
void |
removeDropTargetListener(DropTargetListener dtl) |
addNotify, clearAutoscroll, createDropTargetAutoScroller, createDropTargetContext, getComponent, getDefaultActions, getDropTargetContext, getFlavorMap, initializeAutoscrolling, isActive, removeNotify, setActive, setComponent, setDefaultActions, setFlavorMap, updateAutoscrollpublic MultiDropTarget(Component c, int ops, DropTargetListener dtl)
MultiDropTarget given the Component
to associate itself with, an int representing the default
acceptable action(s) to support, and a DropTargetListener
to handle event processing.
The Component will receive drops only if it is enabled.
c - The Component with which this
DropTarget is associatedops - The default acceptable actions for this
DropTargetdtl - The DropTargetListener for this
DropTargetHeadlessException - if GraphicsEnvironment.isHeadless() returns trueGraphicsEnvironment.isHeadless()public void addDropTargetListener(DropTargetListener dtl)
addDropTargetListener in class DropTargetpublic void removeDropTargetListener(DropTargetListener dtl)
removeDropTargetListener in class DropTargetpublic void dragEnter(DropTargetDragEvent e)
dragEnter in interface DropTargetListenerdragEnter in class DropTargetpublic void dragOver(DropTargetDragEvent e)
dragOver in interface DropTargetListenerdragOver in class DropTargetpublic void dragExit(DropTargetEvent e)
dragExit in interface DropTargetListenerdragExit in class DropTargetpublic void drop(DropTargetDropEvent e)
drop in interface DropTargetListenerdrop in class DropTargetpublic void dropActionChanged(DropTargetDragEvent e)
dropActionChanged in interface DropTargetListenerdropActionChanged in class DropTargetCopyright © 2006–2016 Dirk Lemmermann Software & Consulting. All rights reserved.