This commit is contained in:
parent
be2e39ad6d
commit
7872497479
|
@ -597,8 +597,7 @@ void Form_DeviceConfig::on_sliderClicked(int value)
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
QDoubleSpinBox* doubleSpinBox = reinterpret_cast<QDoubleSpinBox*>(abstractSpinBox);
|
QDoubleSpinBox* doubleSpinBox = reinterpret_cast<QDoubleSpinBox*>(abstractSpinBox);
|
||||||
double temp = value * doubleSpinBox->singleStep();
|
doubleSpinBox->setValue(value / 100.0);
|
||||||
doubleSpinBox->setValue(temp);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
break;
|
break;
|
||||||
|
@ -634,8 +633,7 @@ void Form_DeviceConfig::on_doubleSpinboxClicked(double value)
|
||||||
QString sliderProverty = slider->property("config_name").toString();
|
QString sliderProverty = slider->property("config_name").toString();
|
||||||
if (sliderProverty == spinBoxProverty)
|
if (sliderProverty == spinBoxProverty)
|
||||||
{
|
{
|
||||||
int temp = round(value / spinBox->singleStep());
|
slider->setValue(round(value * 100));
|
||||||
slider->setValue(temp);
|
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue