mirror of
https://github.com/ElvishArtisan/rivendell.git
synced 2025-12-16 09:31:16 +01:00
Do not allow dragging of cuts (child items)
Use enum values for indexing columns
This commit is contained in:
@@ -20,7 +20,7 @@
|
|||||||
//
|
//
|
||||||
|
|
||||||
#include <rdcartdrag.h>
|
#include <rdcartdrag.h>
|
||||||
|
#include <rdlibrary.h>
|
||||||
#include <rdlistviewitem.h>
|
#include <rdlistviewitem.h>
|
||||||
|
|
||||||
#include "globals.h"
|
#include "globals.h"
|
||||||
@@ -50,10 +50,10 @@ void LibListView::contentsMouseMoveEvent(QMouseEvent *e)
|
|||||||
if(item==NULL) {
|
if(item==NULL) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if(item->text(21).isEmpty()) { // Voice tracks cannot be dragged
|
if(item->text(MainWidget::OwnedBy).isEmpty()&&!item->parent()) { // Voice tracks and cuts cannot be dragged
|
||||||
RDCartDrag *d=
|
RDCartDrag *d=
|
||||||
new RDCartDrag(item->text(1).toUInt(),item->text(4),item->textColor(2),
|
new RDCartDrag(item->text(MainWidget::Cart).left(6).toUInt(),item->text(MainWidget::Title),
|
||||||
this);
|
item->textColor(MainWidget::Group), this);
|
||||||
d->dragCopy();
|
d->dragCopy();
|
||||||
emit clicked(item);
|
emit clicked(item);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user