From 8efff0396e9dcc051f7c892c1786dc7bbf945b6d Mon Sep 17 00:00:00 2001 From: tsujan Date: Sat, 8 Apr 2023 20:15:48 +0330 Subject: [PATCH] Fixed a mistake in World-Clock's code when seconds are shown (#1883) The mistake didn't have a serious consequence. Fixes https://github.com/lxqt/lxqt-panel/issues/1882 --- plugin-worldclock/lxqtworldclock.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/plugin-worldclock/lxqtworldclock.cpp b/plugin-worldclock/lxqtworldclock.cpp index 1e6a6449e..375e152f7 100644 --- a/plugin-worldclock/lxqtworldclock.cpp +++ b/plugin-worldclock/lxqtworldclock.cpp @@ -102,7 +102,7 @@ void LXQtWorldClock::updateTimeText() { isUpToDate = false; if (mUpdateInterval < 60000) - mShownTime = tzNow.addSecs(-tzNow.time().msec()); // s + mShownTime = tzNow.addMSecs(-tzNow.time().msec()); // s else if (mUpdateInterval < 3600000) mShownTime = tzNow.addSecs(-tzNow.time().second()); // m else @@ -116,7 +116,7 @@ void LXQtWorldClock::updateTimeText() if (diff < 0 || diff >= 1) { isUpToDate = false; - mShownTime = tzNow.addSecs(-tzNow.time().msec()); + mShownTime = tzNow.addMSecs(-tzNow.time().msec()); } } else if (mUpdateInterval < 3600000)