File Drop fails to call QAbstractItemModel::dropMineData but calls QAbstractItemModel::mimeData instead
-
Hi,
I am building an app with a qTreeview and I created a model which derives from QAbstractItemModel. I can manipulate the tree by dropping a file (dragging a file from outside of the app into the app) and drag-and-drop items within the tree.
The problem is that the file drop into the app doesn't always work since I re-implemented the function mimeData(const QModelIndexList &indexes). Sometimes and only when there is a selected item in the tree (which provides a valid item index to the function mimeData), the file drop doesn't work because the function mimeData is called (and returns true) but the function dropMimeData is never called.
It looks like that the function mimeData should not be called during the file drop as the application knows already the mimeData format: text/uri-list.
Does anybody has the same issue or have any thoughts on this? Again it is not like if it was not working at all, it only fails some of the time.
Any help or thoughts would be great.
Cheers.
-
"You can see the code at the following link":http://stackoverflow.com/questions/18715952/qtreeview-drag-and-drop-fails-to-call-qabstractitemmodeldropminedata-source
-
@
@