Fix DnD onto desktop:/ app desktop file.

We need to resolve from desktop:/ to file:/ so that DropJob
can handle application .desktop files.

CCBUG: 363991
This commit is contained in:
David Faure 2016-06-16 15:34:44 +02:00
parent 0cbc3d195b
commit f2772c4fe6
2 changed files with 2 additions and 2 deletions

View file

@ -240,7 +240,7 @@ void FoldersPanel::slotItemDropEvent(int index, QGraphicsSceneDragDropEvent* eve
event->buttons(),
event->modifiers());
KIO::DropJob *job = DragAndDropHelper::dropUrls(destItem.url(), &dropEvent, this);
KIO::DropJob *job = DragAndDropHelper::dropUrls(destItem.mostLocalUrl(), &dropEvent, this);
if (job) {
connect(job, &KIO::DropJob::result, this, [this](KJob *job) { if (job->error()) emit errorMessage(job->errorString()); });
}

View file

@ -1031,7 +1031,7 @@ void DolphinView::slotItemDropEvent(int index, QGraphicsSceneDragDropEvent* even
destUrl = url();
} else {
// The item represents a directory or desktop-file
destUrl = destItem.url();
destUrl = destItem.mostLocalUrl();
}
QDropEvent dropEvent(event->pos().toPoint(),