]> cloud.milkyroute.net Git - dolphin.git/blobdiff - src/kcategorizedview.h
This fixes the selection problem with the mouse _only_ for the categorized view....
[dolphin.git] / src / kcategorizedview.h
index 8741a665491e8739c35ce8b2c78ecde9c64098e7..015433ae3bb75a9210aa72858b101c28416b3347 100644 (file)
@@ -1,6 +1,6 @@
 /**
   * This file is part of the KDE project
-  * Copyright (C) 2007 Rafael Fernández López <ereslibre@gmail.com>
+  * Copyright (C) 2007 Rafael Fernández López <ereslibre@kde.org>
   *
   * This library is free software; you can redistribute it and/or
   * modify it under the terms of the GNU Library General Public
@@ -25,7 +25,7 @@
 
 #include <libdolphin_export.h>
 
-class KItemCategorizer;
+class KCategoryDrawer;
 
 /**
   * @short Item view for listing items
@@ -36,7 +36,7 @@ class KItemCategorizer;
   *
   * @see KItemCategorizer, KSortFilterProxyModel
   *
-  * @author Rafael Fernández López <ereslibre@gmail.com>
+  * @author Rafael Fernández López <ereslibre@kde.org>
   */
 class LIBDOLPHINPRIVATE_EXPORT KCategorizedView
     : public QListView
@@ -50,18 +50,13 @@ public:
 
     virtual void setModel(QAbstractItemModel *model);
 
+    void setGridSize(const QSize &size);
+
     virtual QRect visualRect(const QModelIndex &index) const;
 
-    /**
-      * Will return the current categorizer. If none set, this method will
-      * return 0
-      */
-    KItemCategorizer *itemCategorizer() const;
+    KCategoryDrawer *categoryDrawer() const;
 
-    /**
-      * Sets the categorizer to be used. Causes the item view to repaint
-      */
-    void setItemCategorizer(KItemCategorizer *itemCategorizer);
+    void setCategoryDrawer(KCategoryDrawer *categoryDrawer);
 
     virtual QModelIndex indexAt(const QPoint &point) const;
 
@@ -90,6 +85,8 @@ protected:
 
     virtual void dragLeaveEvent(QDragLeaveEvent *event);
 
+    virtual void dropEvent(QDropEvent *event);
+
     virtual QModelIndex moveCursor(CursorAction cursorAction,
                                    Qt::KeyboardModifiers modifiers);
 
@@ -108,7 +105,10 @@ protected Q_SLOTS:
 
     virtual void updateGeometries();
 
-    virtual void slotSortingRoleChanged();
+    virtual void slotLayoutChanged();
+
+    virtual void currentChanged(const QModelIndex &current,
+                                const QModelIndex &previous);
 
 
 private: