mirror of
https://github.com/f4exb/sdrangel.git
synced 2024-11-21 23:55:13 -05:00
valuedialz: Check range against m_valueNew rather than m_value, as that holds the most recently set value
This commit is contained in:
parent
dc7232ee4f
commit
e248d8144c
@ -142,9 +142,9 @@ void ValueDialZ::setValueRange(bool positiveOnly, uint numDigits, qint64 min, qi
|
||||
m_valueMin = positiveOnly ? (min < 0 ? 0 : min) : min;
|
||||
m_valueMax = positiveOnly ? (max < 0 ? 0 : max) : max;
|
||||
|
||||
if(m_value < m_valueMin) {
|
||||
if(m_valueNew < m_valueMin) {
|
||||
setValue(m_valueMin);
|
||||
} else if(m_value > m_valueMax) {
|
||||
} else if(m_valueNew > m_valueMax) {
|
||||
setValue(m_valueMax);
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user