diff options
| author | Tannin <devnull@localhost> | 2013-03-22 18:46:40 +0100 |
|---|---|---|
| committer | Tannin <devnull@localhost> | 2013-03-22 18:46:40 +0100 |
| commit | 0a19f0433992be5f9791c8869380d09cd06b66b8 (patch) | |
| tree | 12399954f7c1156ed1cacb24dac3a8574a513e7f /src/modlistgroupcategoriesproxy.h | |
| parent | 8b4e11060b37ad70754aa665ad59744eadd2dd1e (diff) | |
- support for grouping filters for mod list (incomplete)
- offering multiple options for mod names during installation
- support for renaming profiles
- updated installer plugins
- minor bugfixes
Diffstat (limited to 'src/modlistgroupcategoriesproxy.h')
| -rw-r--r-- | src/modlistgroupcategoriesproxy.h | 40 |
1 files changed, 40 insertions, 0 deletions
diff --git a/src/modlistgroupcategoriesproxy.h b/src/modlistgroupcategoriesproxy.h new file mode 100644 index 00000000..23fd36df --- /dev/null +++ b/src/modlistgroupcategoriesproxy.h @@ -0,0 +1,40 @@ +#ifndef MODLISTGROUPPROXY_H
+#define MODLISTGROUPPROXY_H
+
+#include <QIdentityProxyModel>
+#include <tuple>
+
+class ModListGroupCategoriesProxy : public QAbstractProxyModel
+{
+
+ Q_OBJECT
+
+public:
+
+ explicit ModListGroupCategoriesProxy(QObject *parent = 0);
+
+ virtual int rowCount(const QModelIndex &parent) const;
+ virtual int columnCount(const QModelIndex &parent) const;
+
+ virtual QModelIndex mapToSource(const QModelIndex &proxyIndex) const;
+ virtual QModelIndex mapFromSource(const QModelIndex &sourceIndex) const;
+
+ virtual QModelIndex index(int row, int column, const QModelIndex &parent) const;
+ virtual QModelIndex parent(const QModelIndex &child) const;
+
+ virtual bool hasChildren(const QModelIndex &parent) const;
+
+ virtual QVariant data(const QModelIndex &proxyIndex, int role) const;
+ virtual QVariant headerData(int section, Qt::Orientation orientation, int role) const;
+
+signals:
+
+public slots:
+
+private:
+
+ mutable std::map<QPersistentModelIndex, QPersistentModelIndex> m_IndexMap;
+
+};
+
+#endif // MODLISTGROUPPROXY_H
|
