diff options
author | Tomaz Canabrava <tomaz.canabrava@intel.com> | 2014-10-31 17:26:51 -0200 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2014-10-31 14:58:56 -0700 |
commit | 2f60b73bb1dd3fcfe0c98d8cd9400e23572f1418 (patch) | |
tree | c2c1cc5619502a4b681fd01ffca38b6ccd4dfd50 /qt-ui/models.h | |
parent | 03c22c3b18133ae4e71d69d1c20246bc7fbb83ec (diff) | |
download | subsurface-2f60b73bb1dd3fcfe0c98d8cd9400e23572f1418.tar.gz |
Location Filter, skeleton code.
Signed-off-by: Tomaz Canabrava <tomaz.canabrava@intel.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'qt-ui/models.h')
-rw-r--r-- | qt-ui/models.h | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/qt-ui/models.h b/qt-ui/models.h index fb92d2702..a78c20be0 100644 --- a/qt-ui/models.h +++ b/qt-ui/models.h @@ -461,6 +461,24 @@ private: explicit BuddyFilterModel(QObject *parent = 0); }; +class LocationFilterModel : public QStringListModel, public MultiFilterInterface{ + Q_OBJECT +public: + static LocationFilterModel *instance(); + virtual QVariant data(const QModelIndex &index, int role = Qt::DisplayRole) const; + virtual bool setData(const QModelIndex &index, const QVariant &value, int role = Qt::EditRole); + virtual Qt::ItemFlags flags(const QModelIndex &index) const; + virtual bool filterRow(int source_row, const QModelIndex &source_parent, QAbstractItemModel *sourceModel) const; + bool *checkState; + bool anyChecked; +public +slots: + void repopulate(); + +private: + explicit LocationFilterModel(QObject *parent = 0); +}; + class MultiFilterSortModel : public QSortFilterProxyModel { Q_OBJECT |