Hey Guys,
I currently have a graphics scene with dynamic QGraphicsItems being added to the scene. I would like to snap these items together by dragging one item on top of another and releasing the mouse button.
In the QGraphicsItem class i have the following function
Qt Code:
public void dragEnterEvent(QGraphicsSceneDragDropEvent event) { System.out.println("Dragged on the item"); }To copy to clipboard, switch view to plain text mode
This code works fine when I drag some item from my desktop (say an Excel file), but it doesn't detect any item in my scene beign dragged on top of it.
Any help would really be appreciated.
Thanks
Bookmarks