summaryrefslogtreecommitdiffstats
path: root/framework/settings/resourcelistmodel.h
diff options
context:
space:
mode:
Diffstat (limited to 'framework/settings/resourcelistmodel.h')
-rw-r--r--framework/settings/resourcelistmodel.h26
1 files changed, 26 insertions, 0 deletions
diff --git a/framework/settings/resourcelistmodel.h b/framework/settings/resourcelistmodel.h
new file mode 100644
index 00000000..de1b5a51
--- /dev/null
+++ b/framework/settings/resourcelistmodel.h
@@ -0,0 +1,26 @@
1#pragma once
2
3#include <QIdentityProxyModel>
4#include <QSharedPointer>
5#include <QStringList>
6
7class ResourceListModel : public QIdentityProxyModel
8{
9 Q_OBJECT
10
11public:
12 ResourceListModel(QObject *parent = Q_NULLPTR);
13 ~ResourceListModel();
14
15 QVariant data(const QModelIndex &index, int role = Qt::DisplayRole) const;
16
17 enum Roles {
18 Id = Qt::UserRole + 1,
19 Type
20 };
21
22 QHash<int, QByteArray> roleNames() const;
23
24private:
25 QSharedPointer<QAbstractItemModel> m_model;
26};