From 03113405fc027a6d27555ee3b737fea607a0ecd7 Mon Sep 17 00:00:00 2001 From: wmayer Date: Sun, 7 Jun 2020 11:30:56 +0200 Subject: [PATCH] Gui: [skip ci] fix bug when keyboard tracking for QuantitySpinBox is disabled and value is changed by mouse wheel or the spin buttons --- src/Gui/QuantitySpinBox.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/Gui/QuantitySpinBox.cpp b/src/Gui/QuantitySpinBox.cpp index 86d8ac8668..834ebdc554 100644 --- a/src/Gui/QuantitySpinBox.cpp +++ b/src/Gui/QuantitySpinBox.cpp @@ -792,6 +792,8 @@ void QuantitySpinBox::stepBy(int steps) { Q_D(QuantitySpinBox); + handlePendingEmit(); + double step = d->singleStep * steps; double val = d->unitValue + step; if (val > d->maximum) @@ -800,7 +802,6 @@ void QuantitySpinBox::stepBy(int steps) val = d->minimum; lineEdit()->setText(QString::fromUtf8("%L1 %2").arg(val).arg(d->unitStr)); - handlePendingEmit(); update(); selectNumber(); }