X-Git-Url: https://cloud.milkyroute.net/gitweb/dolphin.git/blobdiff_plain/e98e218564694ccca6c0a2962e56ffb7256a11ea..148282e2d856b47ceb191eeef4c834118c8cdffd:/src/draganddrophelper.cpp diff --git a/src/draganddrophelper.cpp b/src/draganddrophelper.cpp index d8c55ed12..387448deb 100644 --- a/src/draganddrophelper.cpp +++ b/src/draganddrophelper.cpp @@ -101,13 +101,8 @@ void DragAndDropHelper::dropUrls(const KFileItem& destItem, QDBusConnection::sessionBus().call(message); } else { const KUrl::List urls = KUrl::List::fromMimeData(event->mimeData()); - const KUrl sourceDir = KUrl(urls.first().directory()); - if (sourceDir == destination) { - const QString msg = i18ncp("@info:status", - "The dropped item is already inside the folder %2", - "The dropped items are already inside the folder %2", - urls.count(), destination.fileName()); - emit informationMessage(msg); + if ((urls.count() == 1) && (urls.first() == destination)) { + emit errorMessage(i18nc("@info:status", "A folder cannot be dropped into itself")); } else if (dropToItem) { KonqOperations::doDrop(destItem, destination, event, widget); } else {