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

setDropAction() is not respected in ItemViews during move operation on MAC

    XMLWordPrintable

Details

    • macOS
    • 137cbd1c7200809cc3945c6d4b6deee560cdc9fc (qt/qtbase/5.13) a014300898bd3bd574ef19bba7123d4b5a07789b (qt/tqtc-qtbase/dev) 14544cc5ecb7a21e8c9b5e6d7c238fc8db68ae4f (qt/qtbase/6.1) 4ef45d66405147458b3bffda0545a2e7453c8665 (qt/qtbase/6.0)
    • Bug Fixing Candidates, UI Bug Fixing Q1/2021

    Description

      The Cocoa platform plugin does not respect QDropEvent::setDropAction(). If dropAction is set to Qt::IgnoreAction, even that QTreeWidget::dropEvent deletes the item that has been moved.
      It is working fine with Windows, issue is only on MAC.
      Please refer to the attached sample.

      1. While pressing the appropriate "Move" modifier key (e.g. Cmd on Mac, Shift on Windows),
      2. drag and drop Item F from Folder 2 to Folder 1.
      3. On Windows and Linux, this properly "moves" the item from one folder
      to the other.
      On the Mac, this causes both F and G items from Folder 2 to disappear.

      The use-case for this is to track the items deleted and does not want the base implementation to do the deletion of moved item from the source. Ideally pEvent->setDropAction(Qt::IgnoreAction) should have worked.

      Attachments

        Issue Links

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

          Activity

            People

              vhilshei Volker Hilsheimer
              shmittal Shveta Mittal (Inactive)
              Votes:
              1 Vote for this issue
              Watchers:
              6 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: