summaryrefslogtreecommitdiffstats
path: root/tests/auto/qgraphicsproxywidget
diff options
context:
space:
mode:
authorMartin Smith <msmith@trolltech.com>2010-05-12 13:12:13 (GMT)
committerMartin Smith <msmith@trolltech.com>2010-05-12 13:12:13 (GMT)
commitbd11cdf472674af3b00d7d64c64023adbf5ee725 (patch)
tree99eb333a12f7e0d109b9ce9ff51120c612669d7a /tests/auto/qgraphicsproxywidget
parent50fa9ebe8fc0e7eca7536a8663c86cd6b98b2c04 (diff)
parent0ebc9783d8ca0c4b27208bbc002c53c52c19ab4c (diff)
downloadQt-bd11cdf472674af3b00d7d64c64023adbf5ee725.zip
Qt-bd11cdf472674af3b00d7d64c64023adbf5ee725.tar.gz
Qt-bd11cdf472674af3b00d7d64c64023adbf5ee725.tar.bz2
Merge branch '4.7' of git@scm.dev.nokia.troll.no:qt/oslo-staging-1 into 4.7
Diffstat (limited to 'tests/auto/qgraphicsproxywidget')
-rw-r--r--tests/auto/qgraphicsproxywidget/tst_qgraphicsproxywidget.cpp15
1 files changed, 15 insertions, 0 deletions
diff --git a/tests/auto/qgraphicsproxywidget/tst_qgraphicsproxywidget.cpp b/tests/auto/qgraphicsproxywidget/tst_qgraphicsproxywidget.cpp
index d5f63d3..6cea834 100644
--- a/tests/auto/qgraphicsproxywidget/tst_qgraphicsproxywidget.cpp
+++ b/tests/auto/qgraphicsproxywidget/tst_qgraphicsproxywidget.cpp
@@ -3436,6 +3436,21 @@ void tst_QGraphicsProxyWidget::inputMethod()
qApp->sendEvent(proxy, &event);
QCOMPARE(lineEdit->inputMethodEvents, i);
}
+
+ scene.clear();
+ QGraphicsView view(&scene);
+ QWidget *w = new QWidget;
+ w->setLayout(new QVBoxLayout(w));
+ QLineEdit *lineEdit = new QLineEdit;
+ lineEdit->setEchoMode(QLineEdit::Password);
+ w->layout()->addWidget(lineEdit);
+ lineEdit->setAttribute(Qt::WA_InputMethodEnabled, true);
+ QGraphicsProxyWidget *proxy = scene.addWidget(w);
+ view.show();
+ QTest::qWaitForWindowShown(&view);
+ QTRY_VERIFY(!(proxy->flags() & QGraphicsItem::ItemAcceptsInputMethod));
+ lineEdit->setFocus();
+ QVERIFY((proxy->flags() & QGraphicsItem::ItemAcceptsInputMethod));
}
void tst_QGraphicsProxyWidget::clickFocus()