From aabb92746d02ed05baccf72c2905c9d4203d15f2 Mon Sep 17 00:00:00 2001 From: Lars Knoll Date: Thu, 8 Sep 2011 14:41:51 +0200 Subject: [PATCH] Adjust to the changes in the QInputMethodQuery event. Change-Id: I0c160f7635c87f63990ddc519cbc966ccab65f4a Reviewed-on: http://codereview.qt-project.org/4447 Reviewed-by: Qt Sanity Bot Reviewed-by: Joona Petrell --- src/declarative/items/qsgitem.cpp | 11 +++++++++-- 1 files changed, 9 insertions(+), 2 deletions(-) diff --git a/src/declarative/items/qsgitem.cpp b/src/declarative/items/qsgitem.cpp index d3b3e0b..addb046 100644 --- a/src/declarative/items/qsgitem.cpp +++ b/src/declarative/items/qsgitem.cpp @@ -4904,8 +4904,15 @@ bool QSGItem::event(QEvent *ev) #endif if (ev->type() == QEvent::InputMethodQuery) { QInputMethodQueryEvent *query = static_cast(ev); - query->setValue(inputMethodQuery(query->query())); - ev->accept(); + Qt::InputMethodQueries queries = query->queries(); + for (uint i = 0; i < 32; ++i) { + Qt::InputMethodQuery q = (Qt::InputMethodQuery)(int)(queries & (1<setValue(q, v); + } + } + query->accept(); return true; } else if (ev->type() == QEvent::InputMethod) { inputMethodEvent(static_cast(ev)); -- 1.7.2.5