Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

jpl2.link.gui
Class JavaDragAndDrop  view JavaDragAndDrop download JavaDragAndDrop.java

java.lang.Object
  extended byjpl2.link.gui.JavaDragAndDrop
All Implemented Interfaces:
DragAndDrop, java.awt.dnd.DropTargetListener, java.util.EventListener

public class JavaDragAndDrop
extends java.lang.Object
implements java.awt.dnd.DropTargetListener, DragAndDrop

For people running 1.2+


Field Summary
private  PsionBrowserPane browserPane
           
private  java.awt.dnd.DropTarget dropTarget
           
private  java.io.File[] files
           
private  jpl2.PsionLink link
           
 
Constructor Summary
JavaDragAndDrop()
           
 
Method Summary
private  boolean canAccept(java.awt.dnd.DropTargetDragEvent dtde)
           
private  boolean canAccept(java.awt.dnd.DropTargetDropEvent dtde)
           
 void dragEnter(java.awt.dnd.DropTargetDragEvent dtde)
          Called when the cursor hotspot enters a drop site which will accept the drag.
 void dragExit(java.awt.dnd.DropTargetEvent dte)
          Called when the cursor hotspot moves outside of a drop site which will accept the drag.
 void dragOver(java.awt.dnd.DropTargetDragEvent dtde)
          Called when the cursor hotspot moves inside of a drop site which will accept the drag.
 void drop(java.awt.dnd.DropTargetDropEvent dtde)
          Called when the drag operation has terminated with a drop.
 void dropActionChanged(java.awt.dnd.DropTargetDragEvent dtde)
          Called when the user modifies the drop gesture.
private  void dumpTransferable(java.awt.datatransfer.Transferable trans)
           
private  java.io.File[] getFiles(java.awt.dnd.DropTargetDropEvent dtde)
           
 void install(jpl2.PsionLink link, PsionBrowserPane browserPane)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

link

private jpl2.PsionLink link

browserPane

private PsionBrowserPane browserPane

dropTarget

private java.awt.dnd.DropTarget dropTarget

files

private java.io.File[] files
Constructor Detail

JavaDragAndDrop

public JavaDragAndDrop()
                throws java.lang.Exception
Method Detail

install

public void install(jpl2.PsionLink link,
                    PsionBrowserPane browserPane)
Specified by:
install in interface DragAndDrop

dragEnter

public void dragEnter(java.awt.dnd.DropTargetDragEvent dtde)
Description copied from interface: java.awt.dnd.DropTargetListener
Called when the cursor hotspot enters a drop site which will accept the drag.

Specified by:
dragEnter in interface java.awt.dnd.DropTargetListener

dragExit

public void dragExit(java.awt.dnd.DropTargetEvent dte)
Description copied from interface: java.awt.dnd.DropTargetListener
Called when the cursor hotspot moves outside of a drop site which will accept the drag. This could also happen if the drop site is no longer active, or no longer accepts the drag.

Specified by:
dragExit in interface java.awt.dnd.DropTargetListener

dragOver

public void dragOver(java.awt.dnd.DropTargetDragEvent dtde)
Description copied from interface: java.awt.dnd.DropTargetListener
Called when the cursor hotspot moves inside of a drop site which will accept the drag.

Specified by:
dragOver in interface java.awt.dnd.DropTargetListener

dropActionChanged

public void dropActionChanged(java.awt.dnd.DropTargetDragEvent dtde)
Description copied from interface: java.awt.dnd.DropTargetListener
Called when the user modifies the drop gesture. This is often the case when additional mouse or key events are received during the drag.

Specified by:
dropActionChanged in interface java.awt.dnd.DropTargetListener

dumpTransferable

private void dumpTransferable(java.awt.datatransfer.Transferable trans)

drop

public void drop(java.awt.dnd.DropTargetDropEvent dtde)
Description copied from interface: java.awt.dnd.DropTargetListener
Called when the drag operation has terminated with a drop.

Specified by:
drop in interface java.awt.dnd.DropTargetListener

canAccept

private boolean canAccept(java.awt.dnd.DropTargetDropEvent dtde)

canAccept

private boolean canAccept(java.awt.dnd.DropTargetDragEvent dtde)

getFiles

private java.io.File[] getFiles(java.awt.dnd.DropTargetDropEvent dtde)