Commit 4de82ca9 authored by Thomas Hartmann's avatar Thomas Hartmann Committed by con

QmlDesigner.propertyEditor: fix opacity slider bug

The granularity of the slider was to fine.
So 1 could be a rounded 0.99.

Task-number: QTCREATORBUG-3035
Reviewed-by: Marco Bubke
parent d4591dd9
......@@ -58,17 +58,17 @@ GroupBox {
SliderWidget {
id: opacitySlider
minimum: 0
maximum: 100
maximum: 10
property variant pureValue: backendValues.opacity.value;
onPureValueChanged: {
if (value != pureValue * 100)
value = pureValue * 100;
if (value != pureValue * 10)
value = pureValue * 10;
}
singleStep: 5;
backendValue: backendValues.opacity
onValueChanged: {
if ((value >= 0) && (value < 100))
backendValues.opacity.value = value / 100;
if ((value >= 0) && (value <= 10))
backendValues.opacity.value = value / 10;
}
}
}
......
Markdown is supported
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