drag-drop in QFilesystemModel
Solved
General and Desktop
-
I am going to develop a linux application with qtreeview and qfilesystemmodel for file management. I had read the article "https://doc.qt.io/qt-5/model-view-programming.html#using-drag-and-drop-with-item-views" . Since the user-case is quite common , I am wondering if it is still necessary to re-implement the functions such as QAbstractItemModel::setData() , QAbstractItemModel::insertRows() , etc. to fulfil the drag and drop ( copy / del / cut /paste ) tasks ? If yes , is there any examples ? Thanks :)
-
Hi and welcome to devnet,
AFAIK, you should not need to do that with QFSM. Making it read/write and activating the drag and drop features of the view should be enough.