From 8998ee8f5163d20a204f2bba8bc240c9bd700be7 Mon Sep 17 00:00:00 2001 From: Peter Penz Date: Tue, 6 Dec 2011 19:20:48 +0100 Subject: Folders Panel cleanups - Reactivate dropping of URLs - Remove unused/obsolete code - Simplify DragAndDropHelper interface --- src/views/draganddrophelper.cpp | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'src/views/draganddrophelper.cpp') diff --git a/src/views/draganddrophelper.cpp b/src/views/draganddrophelper.cpp index 6cd17b6ba..8e5873480 100644 --- a/src/views/draganddrophelper.cpp +++ b/src/views/draganddrophelper.cpp @@ -24,14 +24,13 @@ #include #include #include +#include #include #include -#include QString DragAndDropHelper::dropUrls(const KFileItem& destItem, const KUrl& destPath, - QDropEvent* event, - QWidget* widget) + QDropEvent* event) { const bool dropToItem = !destItem.isNull() && (destItem.isDir() || destItem.isDesktopFile()); const KUrl destination = dropToItem ? destItem.url() : destPath; @@ -49,9 +48,9 @@ QString DragAndDropHelper::dropUrls(const KFileItem& destItem, if (urlsCount == 1 && urls.first() == destination) { return i18nc("@info:status", "A folder cannot be dropped into itself"); } else if (dropToItem) { - KonqOperations::doDrop(destItem, destination, event, widget); + KonqOperations::doDrop(destItem, destination, event, QApplication::activeWindow()); } else { - KonqOperations::doDrop(KFileItem(), destination, event, widget); + KonqOperations::doDrop(KFileItem(), destination, event, QApplication::activeWindow()); } } -- cgit v1.3