summaryrefslogtreecommitdiffstats
path: root/qt-models/filtermodels.cpp
diff options
context:
space:
mode:
authorGravatar Berthold Stoeger <bstoeger@mail.tuwien.ac.at>2018-12-16 20:43:01 +0100
committerGravatar Dirk Hohndel <dirk@hohndel.org>2019-01-19 13:59:24 -0800
commit36fa27050c749717e186c8564d88b11bd53a96c8 (patch)
tree93a3c0248a4406f839cc71455c565c66fe583cf9 /qt-models/filtermodels.cpp
parentcc0c4ab2f16612a145064887614e3f86fe125209 (diff)
downloadsubsurface-36fa27050c749717e186c8564d88b11bd53a96c8.tar.gz
Filter: update filterData directly without copying
In FilterWidget2::updateFilter() a new FilterData object is generated and then copied onto the filterData member variable. Instead, modify filterData directly. This seems also more logical from a semantic point of view: Do we want to reset fields that were not set by the user? Contains trivial whitespace fix. Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
Diffstat (limited to 'qt-models/filtermodels.cpp')
-rw-r--r--qt-models/filtermodels.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/qt-models/filtermodels.cpp b/qt-models/filtermodels.cpp
index 8609243b2..719467fd2 100644
--- a/qt-models/filtermodels.cpp
+++ b/qt-models/filtermodels.cpp
@@ -228,7 +228,7 @@ bool MultiFilterSortModel::lessThan(const QModelIndex &i1, const QModelIndex &i2
return DiveTripModelBase::instance()->lessThan(i1, i2);
}
-void MultiFilterSortModel::filterDataChanged(const FilterData& data)
+void MultiFilterSortModel::filterDataChanged(const FilterData &data)
{
filterData = data;
myInvalidate();