committed by
Bertrand Songis
parent
2f69ee6cbf
commit
3fa82c388a
@@ -67,6 +67,14 @@ class GVarGroup: public QObject {
|
||||
|
||||
void setWeight(int val);
|
||||
|
||||
void setMinimum(int min) {
|
||||
mini = min;
|
||||
}
|
||||
|
||||
void setMaximum(int max) {
|
||||
maxi = max;
|
||||
}
|
||||
|
||||
signals:
|
||||
void valueChanged();
|
||||
|
||||
|
||||
@@ -82,12 +82,14 @@ void LimitsGroup::updateMinMax(int max)
|
||||
{
|
||||
if (spinbox->maximum() == 0) {
|
||||
spinbox->setMinimum(-max * displayStep);
|
||||
gvarGroup->setMinimum(-max);
|
||||
if (value < -max) {
|
||||
value = -max;
|
||||
}
|
||||
}
|
||||
if (spinbox->minimum() == 0) {
|
||||
spinbox->setMaximum(max * displayStep);
|
||||
gvarGroup->setMaximum(max);
|
||||
if (value > max) {
|
||||
value = max;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user