[vlc-devel] [PATCH] Make 1.0x speed accessible from the slider
Romain Vimont
rom1v at videolabs.io
Mon Apr 9 09:14:24 CEST 2018
A slider value change is ignored if the new value is the same as the
last one.
However, the last value was not updated on manual slider move, so its
value remained 0 (speed 2^0 == 1). As a consequence, any slider "move
to 1.0x" event was ignored.
Update the last value on slider move to fix the problem.
Fixes #20170
---
modules/gui/qt/components/interface_widgets.cpp | 1 +
1 file changed, 1 insertion(+)
diff --git a/modules/gui/qt/components/interface_widgets.cpp b/modules/gui/qt/components/interface_widgets.cpp
index 575970c1b8..a47b633f6b 100644
--- a/modules/gui/qt/components/interface_widgets.cpp
+++ b/modules/gui/qt/components/interface_widgets.cpp
@@ -785,6 +785,7 @@ void SpeedControlWidget::updateRate( int sliderValue )
{
if( sliderValue == lastValue )
return;
+ lastValue = sliderValue;
double speed = pow( 2, (double)sliderValue / 17 );
int rate = INPUT_RATE_DEFAULT / speed;
--
2.17.0
More information about the vlc-devel
mailing list