https://bugs.kde.org/show_bug.cgi?id=521347

cwo <[email protected]> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
      Latest Commit|                            |https://invent.kde.org/plas
                   |                            |ma/kdeplasma-addons/-/commi
                   |                            |t/5e85e730984a65e69b3fb5d98
                   |                            |939107eb1281ba3
             Status|ASSIGNED                    |RESOLVED
            Version|                            |6.8.0
  Fixed/Implemented|                            |
                 In|                            |
         Resolution|---                         |FIXED

--- Comment #5 from cwo <[email protected]> ---
Git commit 5e85e730984a65e69b3fb5d98939107eb1281ba3 by Christoph Wolk.
Committed on 30/10/2026 at 08:28.
Pushed by cwo into branch 'master'.

applets/timer: fix progress bar value when switching timer

The progress bar counts down from the starting value in seconds (as
stored in the config) to 0, with the current value being the remaining
number of seconds. When switching to a new timer, we first set up the
new values, then store the current configuration (including the starting
value). The timing works out badly when switching to a longer timer;
let's assume we're switching from a 30 second to a 300 second timer:

Progress bar is at 29 remaining of 30 total (~1%)
 -> seconds is changed to 300
Progress bar is at 30 remaining of 30 total (0%, over max value)
 -> starting seconds is changed to 300
Progress bar is at 30 remaining of 300 total (90%)
 -> noting changes until a second has elapsed
Progress bar is at 299 of 300 total (~0%)

So for a second, the progres bar is confusingly shown as almost
finished, then snaps back to what it should be: just starting.

We could allow larger values, but that still leaves potential binding
order issues. Instead we set the starting value immediately before
changing the current (seconds) state, which makes the immediately
following value update in the same function/handler process correctly.
FIXED-IN: 6.8.0

M  +2    -0    applets/timer/CompactRepresentation.qml
M  +4    -1    applets/timer/TimerView.qml
M  +3    -1    applets/timer/main.qml

https://invent.kde.org/plasma/kdeplasma-addons/-/commit/5e85e730984a65e69b3fb5d98939107eb1281ba3

-- 
You are receiving this mail because:
You are watching all bug changes.

Reply via email to