Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-86020

Items removed from QListWidget during InternalMove

    XMLWordPrintable

Details

    • macOS, Windows
    • 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.

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            qt.team.quick.subscriptions Qt Quick and Widgets Team
            alexmont Alex Montgomery
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes