summaryrefslogtreecommitdiffstats
path: root/desktop-widgets/mainwindow.cpp
diff options
context:
space:
mode:
authorGravatar Berthold Stoeger <bstoeger@mail.tuwien.ac.at>2020-06-22 14:05:46 +0200
committerGravatar Dirk Hohndel <dirk@hohndel.org>2020-09-29 16:13:03 -0700
commit38b686687faed3f8f60828105a2036d5f4e48db6 (patch)
tree5bbaa2f97566bb01a77a38906304470f62d9ae94 /desktop-widgets/mainwindow.cpp
parent68fffc267212470f6d5eb218744b29a851f61cc2 (diff)
downloadsubsurface-38b686687faed3f8f60828105a2036d5f4e48db6.tar.gz
cleanup: move shown-text calculation from filter widget to core
The filter widget was caching whether the filter was active and used that flag to calculate the "# dives shown" string. Move this directly to the DiveFilter class to remove interdependencies and to unify with mobile. Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
Diffstat (limited to 'desktop-widgets/mainwindow.cpp')
-rw-r--r--desktop-widgets/mainwindow.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/desktop-widgets/mainwindow.cpp b/desktop-widgets/mainwindow.cpp
index d4bbc1384..1683a4122 100644
--- a/desktop-widgets/mainwindow.cpp
+++ b/desktop-widgets/mainwindow.cpp
@@ -1536,7 +1536,7 @@ void MainWindow::setTitle()
}
QString unsaved = (unsavedChanges() ? " *" : "");
- QString shown = QString(" (%1)").arg(filterWidget2.shownText());
+ QString shown = QString(" (%1)").arg(DiveFilter::instance()->shownText());
setWindowTitle("Subsurface: " + displayedFilename(existing_filename) + unsaved + shown);
}