aboutsummaryrefslogtreecommitdiff
path: root/launcher/MainWindow.cpp
diff options
context:
space:
mode:
authorPetr Mrázek <peterix@users.noreply.github.com>2021-10-24 01:21:26 +0200
committerGitHub <noreply@github.com>2021-10-24 01:21:26 +0200
commitcbe1b3353c1b3c4562ae00188166a9b14f89c81f (patch)
tree5782f10451edd3efe879a5deeef0f4e61277d008 /launcher/MainWindow.cpp
parent98887911c15dc407e797998cf04e0b90b6aa09ae (diff)
parent2e60413f7fa4b5ce376de7abdb3b5e8a4e0a5d28 (diff)
downloadPrismLauncher-cbe1b3353c1b3c4562ae00188166a9b14f89c81f.tar.gz
PrismLauncher-cbe1b3353c1b3c4562ae00188166a9b14f89c81f.tar.bz2
PrismLauncher-cbe1b3353c1b3c4562ae00188166a9b14f89c81f.zip
Merge pull request #4172 from jamierocks/global-playtime
NOISSUE Add option to disable global play time status
Diffstat (limited to 'launcher/MainWindow.cpp')
-rw-r--r--launcher/MainWindow.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/launcher/MainWindow.cpp b/launcher/MainWindow.cpp
index 33d9c7f4..0c414285 100644
--- a/launcher/MainWindow.cpp
+++ b/launcher/MainWindow.cpp
@@ -1610,6 +1610,7 @@ void MainWindow::globalSettingsClosed()
proxymodel->invalidate();
proxymodel->sort(0);
updateToolsMenu();
+ updateStatusCenter();
update();
}
@@ -1927,6 +1928,8 @@ void MainWindow::checkInstancePathForProblems()
void MainWindow::updateStatusCenter()
{
+ m_statusCenter->setVisible(LAUNCHER->settings()->get("ShowGlobalGameTime").toBool());
+
int timePlayed = LAUNCHER->instances()->getTotalPlayTime();
if (timePlayed > 0) {
m_statusCenter->setText(tr("Total playtime: %1").arg(Time::prettifyDuration(timePlayed)));