diff options
author | Tomaz Canabrava <tomaz.canabrava@intel.com> | 2014-10-31 15:27:33 -0200 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2014-10-31 13:52:51 -0700 |
commit | c68a94da6ade76a6ffe46c959c5b67446131aa72 (patch) | |
tree | fa0acd31531260076844e26ec97bad83b1753653 /qt-ui/models.cpp | |
parent | 19ac1dfa0983b98d9cc2680e9553020d1c936bb9 (diff) | |
download | subsurface-c68a94da6ade76a6ffe46c959c5b67446131aa72.tar.gz |
TagFilter -> MultiFilter
Signed-off-by: Tomaz Canabrava <tomaz.canabrava@intel.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'qt-ui/models.cpp')
-rw-r--r-- | qt-ui/models.cpp | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/qt-ui/models.cpp b/qt-ui/models.cpp index 4b86605d3..e4df20504 100644 --- a/qt-ui/models.cpp +++ b/qt-ui/models.cpp @@ -2351,17 +2351,17 @@ bool TagFilterModel::filterRow(int source_row, const QModelIndex &source_parent, return false; } -TagFilterSortModel *TagFilterSortModel::instance() +MultiFilterSortModel *MultiFilterSortModel::instance() { - static TagFilterSortModel *self = new TagFilterSortModel(); + static MultiFilterSortModel *self = new MultiFilterSortModel(); return self; } -TagFilterSortModel::TagFilterSortModel(QObject *parent) : QSortFilterProxyModel(parent) +MultiFilterSortModel::MultiFilterSortModel(QObject *parent) : QSortFilterProxyModel(parent) { } -bool TagFilterSortModel::filterAcceptsRow(int source_row, const QModelIndex &source_parent) const +bool MultiFilterSortModel::filterAcceptsRow(int source_row, const QModelIndex &source_parent) const { if (models.isEmpty()) { return true; @@ -2376,12 +2376,12 @@ bool TagFilterSortModel::filterAcceptsRow(int source_row, const QModelIndex &sou return false; } -void TagFilterSortModel::myInvalidate() +void MultiFilterSortModel::myInvalidate() { invalidate(); } -void TagFilterSortModel::addFilterModel(MultiFilterInterface *model) +void MultiFilterSortModel::addFilterModel(MultiFilterInterface *model) { QAbstractItemModel *itemModel = dynamic_cast<QAbstractItemModel *>(model); Q_ASSERT(itemModel); @@ -2389,7 +2389,7 @@ void TagFilterSortModel::addFilterModel(MultiFilterInterface *model) connect(itemModel, SIGNAL(dataChanged(QModelIndex, QModelIndex)), this, SLOT(myInvalidate())); } -void TagFilterSortModel::removeFilterModel(MultiFilterInterface *model) +void MultiFilterSortModel::removeFilterModel(MultiFilterInterface *model) { QAbstractItemModel *itemModel = dynamic_cast<QAbstractItemModel *>(model); Q_ASSERT(itemModel); |