dguitar.gui.listeners
Class ADropTargetListener

java.lang.Object
  extended bydguitar.gui.listeners.ADropTargetListener
All Implemented Interfaces:
java.awt.dnd.DropTargetListener, java.util.EventListener

public class ADropTargetListener
extends java.lang.Object
implements java.awt.dnd.DropTargetListener

The Drop action happens in this order: 1. dragEnter = when the mouse enters the component 2. dragOver = after the mouse has entered but has not been released 3. drop = when the mouse is released

Author:
Mauricio Gracia G

Field Summary
private  DGuitar parent
           
 
Constructor Summary
ADropTargetListener(DGuitar dguitar)
           
 
Method Summary
 boolean canImport(java.awt.datatransfer.DataFlavor[] flavors)
           
private  java.util.List convertStringsToFileList(java.lang.String filestr)
           
 void dragEnter(java.awt.dnd.DropTargetDragEvent dtde)
           
 void dragExit(java.awt.dnd.DropTargetEvent dte)
           
 void dragOver(java.awt.dnd.DropTargetDragEvent dtde)
           
 void drop(java.awt.dnd.DropTargetDropEvent dtde)
           
 void dropActionChanged(java.awt.dnd.DropTargetDragEvent dtde)
           
 void importData(DGuitar dguitar, java.awt.datatransfer.Transferable t)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

parent

private DGuitar parent
Constructor Detail

ADropTargetListener

public ADropTargetListener(DGuitar dguitar)
Method Detail

drop

public void drop(java.awt.dnd.DropTargetDropEvent dtde)
Specified by:
drop in interface java.awt.dnd.DropTargetListener

importData

public void importData(DGuitar dguitar,
                       java.awt.datatransfer.Transferable t)

convertStringsToFileList

private java.util.List convertStringsToFileList(java.lang.String filestr)

canImport

public boolean canImport(java.awt.datatransfer.DataFlavor[] flavors)

dragEnter

public void dragEnter(java.awt.dnd.DropTargetDragEvent dtde)
Specified by:
dragEnter in interface java.awt.dnd.DropTargetListener

dragOver

public void dragOver(java.awt.dnd.DropTargetDragEvent dtde)
Specified by:
dragOver in interface java.awt.dnd.DropTargetListener

dropActionChanged

public void dropActionChanged(java.awt.dnd.DropTargetDragEvent dtde)
Specified by:
dropActionChanged in interface java.awt.dnd.DropTargetListener

dragExit

public void dragExit(java.awt.dnd.DropTargetEvent dte)
Specified by:
dragExit in interface java.awt.dnd.DropTargetListener