Commit c3610a8a authored by Kai Uwe Broulik's avatar Kai Uwe Broulik 🍇
Browse files

[Media Controller] Explicitly set slider "to" before setting "value"

Slider refuses to set a value beyond its end, make sure "to" is up-to-date
before we attempt to set "value".

Position changed may be emitted before Length change was emitted.

Fixes media controller position not being up to date on first open.


(cherry picked from commit 1172054d)
parent fbedaedb
Pipeline #153558 passed with stage
in 10 minutes and 54 seconds
......@@ -60,6 +60,8 @@ PlasmaExtras.Representation {
if (!seekSlider.pressed && !keyPressed) {
// we also don't want passive position updates
disablePositionUpdate = true
// Slider refuses to set value beyond its end, make sure "to" is up-to-date first
seekSlider.to = length;
seekSlider.value = position
disablePositionUpdate = false
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment