]> cloud.milkyroute.net Git - dolphin.git/blobdiff - src/treeviewsidebarpage.h
some cleanups for the sidebar pages (move protected members to private section etc.)
[dolphin.git] / src / treeviewsidebarpage.h
index c8aec9e4e023b8d4282ab69133da88c627984968..b7c5e25ff74c895ffb1392775c927245c99a1fde 100644 (file)
@@ -42,13 +42,16 @@ class TreeViewSidebarPage : public SidebarPage
     Q_OBJECT
 
 public:
-    TreeViewSidebarPage(DolphinMainWindow* mainWindow, QWidget* parent = 0);
+    TreeViewSidebarPage(QWidget* parent = 0);
     virtual ~TreeViewSidebarPage();
 
-protected:
-    /** @see SidebarPage::activeViewChanged() */
-    virtual void activeViewChanged();
+public slots:
+    /**
+     * Changes the current selection inside the tree to \a url.
+     */
+    virtual void setUrl(const KUrl& url);
 
+protected:
     /** @see QWidget::showEvent() */
     virtual void showEvent(QShowEvent* event);
 
@@ -56,12 +59,6 @@ protected:
     virtual void contextMenuEvent(QContextMenuEvent* event);
 
 private slots:
-    /**
-     * Updates the current selection inside the tree to
-     * \a url.
-     */
-    void updateSelection(const KUrl& url);
-
     /**
      * Expands the tree in a way that the item with the URL m_selectedUrl
      * gets visible. Is called by TreeViewSidebarPage::updateSelection()
@@ -81,19 +78,11 @@ private slots:
     void dropUrls(const KUrl::List& urls,
                   const QModelIndex& index);
 
-private:
-    /**
-     * Connects to signals from the currently active Dolphin view to get
-     * informed about highlighting changes.
-     */
-    void connectToActiveView();
-
 private:
     KDirLister* m_dirLister;
     KDirModel* m_dirModel;
     DolphinSortFilterProxyModel* m_proxyModel;
     SidebarTreeView* m_treeView;
-    KUrl m_selectedUrl;
 };
 
 #endif // TREEVIEWSIDEBARPAGE_H