提交 bf4ad780 编写于 作者: K Kurt Kartaltepe 提交者: Matt Gajownik

UI: Fix disabled sliders

Previously sliders would not be disabled when the the obs_property was
disabled.
上级 aa713e07
......@@ -329,8 +329,7 @@ void OBSPropertiesView::AddInt(obs_property_t *prop, QFormLayout *layout,
int val = (int)obs_data_get_int(settings, name);
QSpinBox *spin = new SpinBoxIgnoreScroll();
if (!obs_property_enabled(prop))
spin->setEnabled(false);
spin->setEnabled(obs_property_enabled(prop));
int minVal = obs_property_int_min(prop);
int maxVal = obs_property_int_max(prop);
......@@ -354,6 +353,7 @@ void OBSPropertiesView::AddInt(obs_property_t *prop, QFormLayout *layout,
slider->setPageStep(stepVal);
slider->setValue(val);
slider->setOrientation(Qt::Horizontal);
slider->setEnabled(obs_property_enabled(prop));
subLayout->addWidget(slider);
connect(slider, SIGNAL(valueChanged(int)), spin,
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册