Details
-
Bug
-
Resolution: Done
-
P2: Important
-
5.12.8
-
None
-
-
12d8bb0709bf7982061cb0c3e608e4a581892e35 (qt/qtbase/dev) 93e4f88204e604d9196c99c297b081e3f61b7a1c (qt/qtbase/6.0)
Description
Dragging and dropping an item from a QListWidget whose dragDropMode is set to QAbstractItemView::InternalMove to an external application that accepts the mime will cause the item to be deleted from the QListWidget. Notably (and ironically), this includes the Trash Can on Mac and the Recycling Bin on Windows. There's no easy way to work around this, since the behavior occurs during the QDrag::exec() call in QListView::startDrag() and can't be overridden without creating your own startDrag() method that does similar magic to the default QListView implementation.
Example attached. Just drag any entry from the list widget to the trash or recycling bin.