|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.activemath.author.toc.EditableTOCJTreeDropTarget
public class EditableTOCJTreeDropTarget
A drop target implementation that may be attached to any TOC Frame
| Field Summary | |
|---|---|
protected DropTarget |
dt
|
| Constructor Summary | |
|---|---|
EditableTOCJTreeDropTarget(EditableTOCJTree tree)
|
|
| Method Summary | |
|---|---|
boolean |
acceptOrReject(DropTargetDragEvent dtde)
calls either dtde.acceptDrag or dtde.rejectDrag, depending on actionType. |
void |
checkFlavor(DropTargetDragEvent dtde)
checks if the drag source of the given Event is able to supply file lists, and sets the dropAcceptable flag accordingly. |
void |
dragEnter(DropTargetDragEvent dtde)
called when cursor enters droptarget's component checks if a dnd operation from the DragEvent's DragSource to this DropTargetListener's Component is allowed. |
void |
dragExit(DropTargetEvent dte)
called when the mouse, while dragging something, leaves the Component that belongs to this Listener, or when a drop occurs. |
void |
dragOver(DropTargetDragEvent dtde)
called when the mouse moves over this Listener's Component during a dnd operation. |
void |
drop(DropTargetDropEvent dtde)
called if something is actually dropped inside the Component this Listener is attached to. |
void |
dropActionChanged(DropTargetDragEvent dtde)
called when the type of dnd-action is changed, for example if the user presses SHIFT/ALT/CTRL etc. |
boolean |
isURL(DropTargetDragEvent dtde)
checks whether the data inside the given DropTargetDragEvent is a string that starts with 'http://' |
static String |
readURLFromEvent(DropTargetDropEvent dtde)
Tries to match the possible data-flavours to get the and returns it if found or null otherwise. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected DropTarget dt
| Constructor Detail |
|---|
public EditableTOCJTreeDropTarget(EditableTOCJTree tree)
| Method Detail |
|---|
public void checkFlavor(DropTargetDragEvent dtde)
public boolean isURL(DropTargetDragEvent dtde)
public boolean acceptOrReject(DropTargetDragEvent dtde)
public void dragEnter(DropTargetDragEvent dtde)
dragEnter in interface DropTargetListenerpublic void dragOver(DropTargetDragEvent dtde)
dragOver in interface DropTargetListenerpublic void dropActionChanged(DropTargetDragEvent dtde)
dropActionChanged in interface DropTargetListenerpublic void dragExit(DropTargetEvent dte)
dragExit in interface DropTargetListenerpublic void drop(DropTargetDropEvent dtde)
drop in interface DropTargetListener
public static String readURLFromEvent(DropTargetDropEvent dtde)
throws Exception
null otherwise.
Exception
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||