From c5606041e139189ab8b52107f88dd599a549d371 Mon Sep 17 00:00:00 2001 From: NamedKitten Date: Wed, 21 Nov 2018 14:44:17 +0000 Subject: [PATCH] [UI] I fail at maths. --- src/qml/ControlsBar.qml | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/qml/ControlsBar.qml b/src/qml/ControlsBar.qml index d662fd8..33a1024 100644 --- a/src/qml/ControlsBar.qml +++ b/src/qml/ControlsBar.qml @@ -120,8 +120,7 @@ Item { progressBar.to = duration }) player.cachedDurationChanged.connect(function(duration) { - cachedLength.width = ((progressBar.width / progressBar.to) - * duration) - progressLength.width + cachedLength.width = progressBackground.width / progressBar.to * duration }) } onMoved: { @@ -176,7 +175,7 @@ Item { } Rectangle { id: cachedLength - z: 10 + z: 100 radius: height anchors.left: progressLength.right anchors.leftMargin: 2 @@ -190,7 +189,6 @@ Item { } handle: Rectangle { - id: handleRect x: progressBar.leftPadding + progressBar.visualPosition * (progressBar.availableWidth - width)