Hi!
I use a custom startDrag to avoid the pixmap which is annoying during the drag.
All worked good until Qt6, if I remove my custom startDrag everything works good but with the pixmap that I would avoid.
Here how I do the custom startDrag:
void startDrag(Qt::DropActions supportedActions) override
{
drag->setMimeData(mimeData(selectedItems()));
drag->exec(supportedActions);
}
void startDrag(Qt::DropActions supportedActions) override
{
QDrag* drag = new QDrag(this);
drag->setMimeData(mimeData(selectedItems()));
drag->exec(supportedActions);
}
To copy to clipboard, switch view to plain text mode
What would be the thing that Qt6 doesn't like with this particular piece of code where the non-override works perfectly fine?
Would be nice to have an option to disable pixmap on drag and drop for QTreeWidget/QListWidget one day surely for this kind of case when you don't want a pixmap.
Thanks a lot!
Bookmarks