All Packages Class Hierarchy This Package Previous Next Index
Interface com.ibm.dnd.DDTarget
- public interface DDTarget
The interface for objects that handle DnD events for a
particular drop target component.
-
dragEnter()
- As the mouse enters the drop target component.
-
dragExit()
- As the mouse exits the drop target component.
-
dragOver(DataFlavorRecognizer, Point)
- As the mouse passes the drop target component.
-
drop(Transferable, Point)
- As the user drops the object.
-
dropComplete()
- As the drop operation completes.
dragEnter
public abstract void dragEnter()
- As the mouse enters the drop target component.
dragExit
public abstract void dragExit()
- As the mouse exits the drop target component.
dragOver
public abstract boolean dragOver(DataFlavorRecognizer dataFlavorRecognizer,
Point location)
- As the mouse passes the drop target component. This method should return
a boolean indicating if DDTarget can accept the drop. The dataFlavorRecognizer
parameter allows finding out if the drag object can be accepted.
- Parameters:
- dataFlavorRecognizer - has the
isDatatFlavorSupported
method
that allows finding out if the drag object is acceptable.
- location - current mouse location (relative to the component)
- See Also:
- DataFlavorRecognizer
drop
public abstract boolean drop(Transferable source,
Point point)
- As the user drops the object. This method is not called if the
dragOver
method returns false (indicating the object is not acceptable).
- Parameters:
- source - java.awt.datatransfer.Transferable the object to drop
- p - java.awt.Point the point in target coordinates
- Returns:
- true on success, false otherwise.
dropComplete
public abstract void dropComplete()
- As the drop operation completes.
All Packages Class Hierarchy This Package Previous Next Index