my dog learned polymorphism*
The moose likes Java in General and the fly likes Transfer handling help Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Java in General
Reply locked New topic
Author

Transfer handling help

Jay Orsaw
Ranch Hand

Joined: Jun 14, 2011
Posts: 356

So I am trying to set up a way to drag items from a list onto a panel or frame... I am using Netbeans so the list has 5 items, and I have set drop to be enabled on it. I am trying to set up the TransferHandler and DropTarget... There is a lot of methods and I'm not really sure how to go about this. I'm reading the Oracle Trail http://docs.oracle.com/javase/tutorial/uiswing/dnd/transferhandler.html and so far it seems like I need to set the source and stuff for the export(which is already set up it seems when I click "dropEnabled" in the gui), but now I need to setup the transfer to be imported....

So far I have this

But I'm not sure if I set that up right....

Let me know if this code is wrong and where I need to change it... I would appreciate any input, and I will be editing this as I try to do this myself...

Thanks ,

~JO
Darryl Burke
Bartender

Joined: May 03, 2008
Posts: 4523
    
    5

Posted again in the GUIs forum. Locking.


luck, db
There are no new questions, but there may be new answers.
 
jQuery in Action, 2nd edition
 
subject: Transfer handling help
 
Similar Threads
How to change mouse cursor during drag and drop
drag and drop DND click, then move??
Unexpected thread behavior
Cannot get TransferHandler to work in Swing
Add Drag and Drop functionality to JPanel?