diff options
author | Berthold Stoeger <bstoeger@mail.tuwien.ac.at> | 2018-08-14 13:03:33 -0400 |
---|---|---|
committer | Berthold Stoeger <bstoeger@mail.tuwien.ac.at> | 2018-08-14 13:03:33 -0400 |
commit | fb47c15cd81970f19aeb9777c4c576b973889674 (patch) | |
tree | 23845588c6fe9fcb09bc7f46e06ae24fe5882a2f /qt-models/filtermodels.h | |
parent | 612f1b478f785331504fc4a22c1546536d2f345f (diff) | |
download | subsurface-fb47c15cd81970f19aeb9777c4c576b973889674.tar.gz |
Filter: remove unused parameters from doFilter functions
Change the signature from of the virtual doFilter() functions from
bool doFilter(struct dive *d, QModelIndex&, QAbstractItemModel*) const;
to
bool LocationFilterModel::doFilter(struct dive *d) const;
as the QModelIndex and QAbstractItemModel parameters were not used.
This makes this functions independent from Qt's model/view
framework. This is in preparation for making the undo-machinery
compatible with the filtering.
Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
Diffstat (limited to 'qt-models/filtermodels.h')
-rw-r--r-- | qt-models/filtermodels.h | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/qt-models/filtermodels.h b/qt-models/filtermodels.h index 1d950e735..2ccfec010 100644 --- a/qt-models/filtermodels.h +++ b/qt-models/filtermodels.h @@ -10,7 +10,7 @@ class FilterModelBase : public QStringListModel { Q_OBJECT public: - virtual bool doFilter(struct dive *d, QModelIndex &index0, QAbstractItemModel *sourceModel) const = 0; + virtual bool doFilter(struct dive *d) const = 0; void clearFilter(); void selectAll(); void invertSelection(); @@ -34,7 +34,7 @@ class TagFilterModel : public FilterModelBase { Q_OBJECT public: static TagFilterModel *instance(); - bool doFilter(struct dive *d, QModelIndex &index0, QAbstractItemModel *sourceModel) const; + bool doFilter(struct dive *d) const; public slots: void repopulate(); @@ -48,7 +48,7 @@ class BuddyFilterModel : public FilterModelBase { Q_OBJECT public: static BuddyFilterModel *instance(); - bool doFilter(struct dive *d, QModelIndex &index0, QAbstractItemModel *sourceModel) const; + bool doFilter(struct dive *d) const; public slots: void repopulate(); @@ -62,7 +62,7 @@ class LocationFilterModel : public FilterModelBase { Q_OBJECT public: static LocationFilterModel *instance(); - bool doFilter(struct dive *d, QModelIndex &index0, QAbstractItemModel *sourceModel) const; + bool doFilter(struct dive *d) const; public slots: void repopulate(); @@ -78,7 +78,7 @@ class SuitsFilterModel : public FilterModelBase { Q_OBJECT public: static SuitsFilterModel *instance(); - bool doFilter(struct dive *d, QModelIndex &index0, QAbstractItemModel *sourceModel) const; + bool doFilter(struct dive *d) const; public slots: void repopulate(); |