The simplest example I can think of are playlists, where you can drag a song to a different position in the list.
I've done quite a few things with Swing but I've never seen an example with something like this.
The simplest example I can think of are playlists, where you can drag a song to a different position in the list.
I've done quite a few things with Swing but I've never seen an example with something like this.
Here's an example that might be close to what you want http://www.java2s.com/Code/Java/Swing-JFC/DragandDropJListandList.htm
There is a demo in the Oracle page linked in the comment to the first question: http://download.oracle.com/javase/tutorial/uiswing/dnd/basicdemo.html
Direct link: http://download.oracle.com/javase/tutorial/uiswing/examples/dnd/BasicDnDProject/src/dnd/BasicDnD.java