fixed broken by me drag'n'drop :)
This commit is contained in:
parent
1507faef6e
commit
896b81c999
|
@ -77,6 +77,12 @@ bool OutputColumnModel::removeRows(int position, int rows, const QModelIndex &pa
|
|||
return true;
|
||||
}
|
||||
|
||||
QStringList OutputColumnModel::mimeTypes() const {
|
||||
QStringList types;
|
||||
types << OutputColumnModel::MimeType;
|
||||
return types;
|
||||
}
|
||||
|
||||
bool OutputColumnModel::canDropMimeData(const QMimeData *data, Qt::DropAction action, int, int, const QModelIndex &) {
|
||||
if ( action != Qt::MoveAction || !data->hasFormat(OutputColumnModel::MimeType))
|
||||
return false;
|
||||
|
@ -140,3 +146,4 @@ bool OutputColumnModel::dropMimeData(const QMimeData *data, Qt::DropAction actio
|
|||
|
||||
return true;
|
||||
}
|
||||
|
||||
|
|
|
@ -28,7 +28,7 @@ public:
|
|||
bool insertRows(int position, int rows, const QModelIndex &index = QModelIndex()) override;
|
||||
bool removeRows(int position, int rows, const QModelIndex &index = QModelIndex()) override;
|
||||
|
||||
// QStringList mimeTypes() const override;
|
||||
QStringList mimeTypes() const override;
|
||||
bool canDropMimeData(const QMimeData *, Qt::DropAction, int, int, const QModelIndex&);
|
||||
QMimeData* mimeData(const QModelIndexList &indexes) const override;
|
||||
bool dropMimeData(const QMimeData *data, Qt::DropAction action, int row, int column, const QModelIndex &parent) override;
|
||||
|
|
Loading…
Reference in New Issue