clipboard: vector size only calculated once.

transition: check of t pointer inside the check
sourcescommon: logical expression simplified.
This commit is contained in:
Carmot
2019-01-11 11:51:24 +01:00
parent ee019517b1
commit 652ac72c1c
3 changed files with 6 additions and 4 deletions
+1 -1
View File
@@ -205,7 +205,7 @@ void SourcesCommon::dropEvent(QWidget* parent, QDropEvent *event, const QModelIn
// dragging files within project
// if we dragged to the root OR dragged to a folder
if (!drop_item.isValid() || (drop_item.isValid() && m->get_type() == MEDIA_TYPE_FOLDER)) {
if (!drop_item.isValid() || m->get_type() == MEDIA_TYPE_FOLDER) {
QVector<Media*> move_items;
for (int i=0;i<items.size();i++) {
const QModelIndex& item = items.at(i);