┌   ┐
54
└   ┘

summaryrefslogtreecommitdiff
path: root/src/draganddrophelper.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/draganddrophelper.h')
-rw-r--r--src/draganddrophelper.h27
1 files changed, 26 insertions, 1 deletions
diff --git a/src/draganddrophelper.h b/src/draganddrophelper.h
index 64e347e9c..920ff5135 100644
--- a/src/draganddrophelper.h
+++ b/src/draganddrophelper.h
@@ -1,6 +1,6 @@
/***************************************************************************
* Copyright (C) 2007 by Peter Penz <[email protected]> *
- * *
+ * Copyright (C) 2007 by David Faure <[email protected]> * * *
* This program is free software; you can redistribute it and/or modify *
* it under the terms of the GNU General Public License as published by *
* the Free Software Foundation; either version 2 of the License, or *
@@ -23,6 +23,10 @@
#include <QtCore/Qt>
class DolphinController;
+class KFileItem;
+class KUrl;
+class QDropEvent;
+class QMimeData;
class QAbstractItemView;
class QBrush;
class QRect;
@@ -40,11 +44,32 @@ class DragAndDropHelper
public:
/**
+ * Returns true, if Dolphin supports the dragging of
+ * the given mime data.
+ */
+ static bool isMimeDataSupported(const QMimeData* mimeData);
+
+ /**
* Creates a drag object for the view \a itemView for all selected items.
*/
static void startDrag(QAbstractItemView* itemView,
Qt::DropActions supportedActions,
DolphinController* controller = 0);
+
+ /**
+ * Handles the dropping of URLs to the given
+ * destination. A context menu with the options
+ * 'Move Here', 'Copy Here', 'Link Here' and
+ * 'Cancel' is offered to the user.
+ * @param destItem Item of the destination (can be null, see KFileItem::isNull()).
+ * @param destPath Path of the destination.
+ * @param event Drop event.
+ * @param widget Source widget where the dragging has been started.
+ */
+ static void dropUrls(const KFileItem& destItem,
+ const KUrl& destPath,
+ QDropEvent* event,
+ QWidget* widget);
};
#endif