]> cloud.milkyroute.net Git - dolphin.git/blobdiff - src/dolphinpart.h
Hide the "Sort by Rating" and "Sort by Tags" menu entries for KDE 4.0, as currently...
[dolphin.git] / src / dolphinpart.h
index bf81b55f48d4b8d71b2304fd67c71096f24ca25c..2a512eddb29f0172ae59f44f1d22ed2b82ea4398 100644 (file)
@@ -21,6 +21,8 @@
 #define DOLPHINPART_H
 
 #include <kparts/part.h>
+#include <kparts/browserextension.h>
+class KAction;
 class KFileItemList;
 class KFileItem;
 class DolphinPartBrowserExtension;
@@ -50,6 +52,8 @@ public:
     /// see the supportsUndo property
     bool supportsUndo() const { return true; }
 
+    DolphinView* view() { return m_view; }
+
 protected:
     /**
      * We reimplement openUrl so no need to implement openFile.
@@ -99,6 +103,19 @@ private Q_SLOTS:
      */
     void updateViewActions();
 
+    /**
+     * Updates the text of the paste action dependent from
+     * the number of items which are in the clipboard.
+     */
+    void updatePasteAction();
+
+    /**
+     * Connected to the "move_to_trash" action; adds "shift means del" handling.
+     */
+    void slotTrashActivated(Qt::MouseButtons, Qt::KeyboardModifiers);
+
+    void slotNewDir();
+
 private:
     void createActions();
 
@@ -111,4 +128,20 @@ private:
     Q_DISABLE_COPY(DolphinPart)
 };
 
+class DolphinPartBrowserExtension : public KParts::BrowserExtension
+{
+    Q_OBJECT
+public:
+    DolphinPartBrowserExtension( DolphinPart* part )
+        : KParts::BrowserExtension( part ), m_part(part) {}
+
+public Q_SLOTS:
+    void cut();
+    void copy();
+    void paste();
+
+private:
+    DolphinPart* m_part;
+};
+
 #endif /* DOLPHINPART_H */