summaryrefslogtreecommitdiffstats
path: root/mobile-widgets
diff options
context:
space:
mode:
authorGravatar Dirk Hohndel <dirk@hohndel.org>2018-10-20 12:01:21 -0400
committerGravatar Dirk Hohndel <dirk@hohndel.org>2018-10-23 22:45:30 +0100
commitb0a0e1e3740232e1d83ed3ad5f46c241d7b4c25c (patch)
tree5612fad644f4d9a2a96a25ab4909344e5b8adc5a /mobile-widgets
parent466a0bf75838e67e96b61f296de06205f2177030 (diff)
downloadsubsurface-b0a0e1e3740232e1d83ed3ad5f46c241d7b4c25c.tar.gz
Mobile/filtering: simplify the filter toggle
Simply make it always reset the filter. There's no point remembering the last filter pattern and explicitly setting it, if the last thing we do is to reset this pattern. Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'mobile-widgets')
-rw-r--r--mobile-widgets/qml/DiveList.qml7
1 files changed, 1 insertions, 6 deletions
diff --git a/mobile-widgets/qml/DiveList.qml b/mobile-widgets/qml/DiveList.qml
index d5d85e3a6..489e6b42d 100644
--- a/mobile-widgets/qml/DiveList.qml
+++ b/mobile-widgets/qml/DiveList.qml
@@ -510,12 +510,7 @@ Kirigami.ScrollablePage {
text: qsTr("Filter dives")
onTriggered: {
rootItem.filterToggle = !rootItem.filterToggle
- if (rootItem.filterToggle) {
- diveModel.setFilter(rootItem.filterPattern)
- } else {
- diveModel.resetFilter()
- rootItem.filterPattern = ""
- }
+ diveModel.resetFilter()
}
}