summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatthew Cattell <matthew.cattell@nokia.com>2011-09-28 13:52:59 +0200
committerQt by Nokia <qt-info@nokia.com>2011-09-28 19:40:34 +0200
commitab061e3e436fab35eac8666f3e950e98f66c4d3e (patch)
tree15466415a639dbf8f0a05b0c168ed42e25d366f3
parent353c12f3e6c97d7059365dcf9b1f2dd9aa484545 (diff)
reimplemented doUpdateMicroFocus to work without calling the base implementation
Change-Id: Ic96ab2bb93248e6d3ba1c8b789ed3c21f8ad39bd Reviewed-on: http://codereview.qt-project.org/5716 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com> Reviewed-by: Jo Asplin <jo.asplin@nokia.com> Reviewed-by: Holger Ihrig <holger.ihrig@nokia.com>
-rw-r--r--tests/auto/qgraphicsitem/tst_qgraphicsitem.cpp12
1 files changed, 11 insertions, 1 deletions
diff --git a/tests/auto/qgraphicsitem/tst_qgraphicsitem.cpp b/tests/auto/qgraphicsitem/tst_qgraphicsitem.cpp
index 2d629176f3..ce099e0de9 100644
--- a/tests/auto/qgraphicsitem/tst_qgraphicsitem.cpp
+++ b/tests/auto/qgraphicsitem/tst_qgraphicsitem.cpp
@@ -10393,7 +10393,17 @@ public:
void doUpdateMicroFocus()
{
- updateMicroFocus();
+ if (QWidget *fw = QApplication::focusWidget()) {
+ if (scene()) {
+ for (int i = 0 ; i < scene()->views().count() ; ++i) {
+ if (scene()->views().at(i) == fw) {
+ if (QInputContext *inputContext = fw->inputContext()) {
+ inputContext->update();
+ }
+ }
+ }
+ }
+ }
}
};