mirror of
https://github.com/OPM/ResInsight.git
synced 2026-09-03 20:53:13 -05:00
Added option to hide spin box for sliders.
This commit is contained in:
committed by
Magne Sjaastad
parent
a2ca399dfa
commit
c6e10c9c5d
@@ -82,6 +82,8 @@ void PdmUiSliderEditor::configureAndUpdateUi( const QString& uiConfigName )
|
|||||||
QString textValue = uiField()->uiValue().toString();
|
QString textValue = uiField()->uiValue().toString();
|
||||||
m_spinBox->setValue( textValue.toInt() );
|
m_spinBox->setValue( textValue.toInt() );
|
||||||
m_spinBox->blockSignals( false );
|
m_spinBox->blockSignals( false );
|
||||||
|
|
||||||
|
m_spinBox->setVisible( m_attributes.m_showSpinBox );
|
||||||
}
|
}
|
||||||
|
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -55,13 +55,15 @@ class PdmUiSliderEditorAttribute : public PdmUiEditorAttribute
|
|||||||
public:
|
public:
|
||||||
PdmUiSliderEditorAttribute()
|
PdmUiSliderEditorAttribute()
|
||||||
{
|
{
|
||||||
m_minimum = 0;
|
m_minimum = 0;
|
||||||
m_maximum = 10;
|
m_maximum = 10;
|
||||||
|
m_showSpinBox = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
public:
|
public:
|
||||||
int m_minimum;
|
int m_minimum;
|
||||||
int m_maximum;
|
int m_maximum;
|
||||||
|
bool m_showSpinBox;
|
||||||
};
|
};
|
||||||
|
|
||||||
class PdmUiSliderEditor : public PdmUiFieldEditorHandle
|
class PdmUiSliderEditor : public PdmUiFieldEditorHandle
|
||||||
|
|||||||
Reference in New Issue
Block a user