diff options
| author | littleblack111 <littleblack11111@gmail.com> | 2025-07-15 10:56:34 +0800 |
|---|---|---|
| committer | littleblack111 <littleblack11111@gmail.com> | 2025-07-15 10:56:34 +0800 |
| commit | ca1009140ec99fc20776d7f9ccf907a8a6179a3a (patch) | |
| tree | 2aaa859cc01c131628d5e92310d9c461b37814a1 | |
| parent | 79a735dd9d4a02d40b4a1ec925aa1f6d5b8a6f4e (diff) | |
timedate: fix extra "0" displayed infornt at 10
| -rw-r--r-- | bar/TimeDate.qml | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/bar/TimeDate.qml b/bar/TimeDate.qml index 6ef8596..0a0abb6 100644 --- a/bar/TimeDate.qml +++ b/bar/TimeDate.qml @@ -40,21 +40,22 @@ Item { property int s: Services.TimeDate.seconds spacing: 0 IText { - text: (parent.h > 10 ? "" : "0") + parent.h + animate: true + text: (parent.h >= 10 ? "" : "0") + parent.h } IText { text: ":" } IText { animate: true - text: (parent.m > 10 ? "" : "0") + parent.m + text: (parent.m >= 10 ? "" : "0") + parent.m } IText { text: ":" } IText { animate: true - text: (parent.s > 10 ? "" : "0") + parent.s + text: (parent.s >= 10 ? "" : "0") + parent.s } } Item { |
