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?