0

I am creating a game interface and I have a panel which has a grid layout for inventory spaces. The game has items which are JLabels with icons added to them. I want the items to be draggable, specifically draggable on the inventory spaces and the item should snap to the inventory space

For this, would it be easier to use DnD, or should I use MouseEvents, or is there a more suitable method for this?

mKorbel
  • 109,525
  • 20
  • 134
  • 319
  • Some mouse examples are cited [here](http://stackoverflow.com/a/5312702/230513). – trashgod May 30 '13 at 23:43
  • It depends on how messy you want to get...a possible [example](http://stackoverflow.com/questions/15520610/java-drag-and-drop/15521421#15521421) – MadProgrammer May 31 '13 at 00:19

0 Answers0