summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorDominik Holland <dominik.holland@nokia.com>2010-07-23 08:51:20 (GMT)
committerHarald Fernengel <harald.fernengel@nokia.com>2010-11-02 14:27:28 (GMT)
commit08864c3ec88abf5fdb782ffe972e2576fc703e8c (patch)
treedacaa09bccc98c5752a3f265774e14a5824db62b /tests
parentaf082b6b515d45f905aab29e1b685e91bc6f50cf (diff)
downloadQt-08864c3ec88abf5fdb782ffe972e2576fc703e8c.zip
Qt-08864c3ec88abf5fdb782ffe972e2576fc703e8c.tar.gz
Qt-08864c3ec88abf5fdb782ffe972e2576fc703e8c.tar.bz2
Fixed QBoxLayout autotest to use a dummy toplevel widget
Diffstat (limited to 'tests')
-rw-r--r--tests/auto/qboxlayout/tst_qboxlayout.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/tests/auto/qboxlayout/tst_qboxlayout.cpp b/tests/auto/qboxlayout/tst_qboxlayout.cpp
index c4acfdc..659f8a5 100644
--- a/tests/auto/qboxlayout/tst_qboxlayout.cpp
+++ b/tests/auto/qboxlayout/tst_qboxlayout.cpp
@@ -198,7 +198,8 @@ void tst_QBoxLayout::sizeConstraints()
void tst_QBoxLayout::setGeometry()
{
- QWidget w;
+ QWidget toplevel;
+ QWidget w(&toplevel);
QVBoxLayout *lay = new QVBoxLayout;
lay->setMargin(0);
lay->setSpacing(0);
@@ -209,7 +210,7 @@ void tst_QBoxLayout::setGeometry()
lay2->setAlignment(Qt::AlignRight);
lay->addLayout(lay2);
w.setLayout(lay);
- w.show();
+ toplevel.show();
QRect newGeom(0, 0, 70, 70);
lay2->setGeometry(newGeom);