summaryrefslogtreecommitdiffstats
path: root/tests/auto/qspinbox
diff options
context:
space:
mode:
authorJens Bache-Wiig <jbache@trolltech.com>2009-05-14 14:09:41 (GMT)
committerJens Bache-Wiig <jbache@trolltech.com>2009-05-14 14:11:42 (GMT)
commita2f9d610c5cfd80819dc9a11c9452fcadba6ebb4 (patch)
treef2b34b53343a4530307afc63df018564b9fc78da /tests/auto/qspinbox
parentd45795809de0d5c4bb7a8c4dfd0b786373350c14 (diff)
downloadQt-a2f9d610c5cfd80819dc9a11c9452fcadba6ebb4.zip
Qt-a2f9d610c5cfd80819dc9a11c9452fcadba6ebb4.tar.gz
Qt-a2f9d610c5cfd80819dc9a11c9452fcadba6ebb4.tar.bz2
Fix missing update of edit geometry on QSpinBox
When showing or hiding spinbox buttons we did not update the child line edit geometry. This would on windows basically mean that the buttons would not show up as they were completely covered by the edit. Task-number: 235747 Reviewed-by: ogoffart
Diffstat (limited to 'tests/auto/qspinbox')
-rw-r--r--tests/auto/qspinbox/tst_qspinbox.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/tests/auto/qspinbox/tst_qspinbox.cpp b/tests/auto/qspinbox/tst_qspinbox.cpp
index 1867356..575f261 100644
--- a/tests/auto/qspinbox/tst_qspinbox.cpp
+++ b/tests/auto/qspinbox/tst_qspinbox.cpp
@@ -241,6 +241,12 @@ void tst_QSpinBox::getSetCheck()
QCOMPARE(0.0, obj2.value());
obj2.setValue(1.0);
QCOMPARE(1.0, obj2.value());
+
+ // Make sure we update line edit geometry when updating
+ // buttons - see task 235747
+ QRect oldEditGeometry = obj1.childrenRect();
+ obj1.setButtonSymbols(QAbstractSpinBox::NoButtons);
+ QVERIFY(obj1.childrenRect() != oldEditGeometry);
}
tst_QSpinBox::tst_QSpinBox()