From: Emmanuel Pescosta Date: Mon, 5 Jan 2015 11:50:53 +0000 (+0100) Subject: Always connect the drop job result with DolphinView::slotPasteJobResult X-Git-Url: https://cloud.milkyroute.net/gitweb/dolphin.git/commitdiff_plain/39b77e9861c1318bff1a26627dde3fd1c9c71861 Always connect the drop job result with DolphinView::slotPasteJobResult to receive the error message in case of an error also when the destUrl is not equal to the current url in the view. CCMAIL: faure@kde.org --- diff --git a/src/views/dolphinview.cpp b/src/views/dolphinview.cpp index 32e182ce7..4129cc217 100644 --- a/src/views/dolphinview.cpp +++ b/src/views/dolphinview.cpp @@ -1048,12 +1048,15 @@ void DolphinView::dropUrls(const QUrl &destUrl, QDropEvent *dropEvent) { KIO::DropJob* job = DragAndDropHelper::dropUrls(destUrl, dropEvent, this); - if (job && destUrl == url()) { - // Mark the dropped urls as selected. - m_clearSelectionBeforeSelectingNewItems = true; - m_markFirstNewlySelectedItemAsCurrent = true; - connect(job, &KIO::DropJob::itemCreated, this, &DolphinView::slotItemCreated); + if (job) { connect(job, &KIO::DropJob::result, this, &DolphinView::slotPasteJobResult); + + if (destUrl == url()) { + // Mark the dropped urls as selected. + m_clearSelectionBeforeSelectingNewItems = true; + m_markFirstNewlySelectedItemAsCurrent = true; + connect(job, &KIO::DropJob::itemCreated, this, &DolphinView::slotItemCreated); + } } }