diff options
author | Friedemann Kleint <Friedemann.Kleint@theqtcompany.com> | 2015-09-22 10:57:51 +0200 |
---|---|---|
committer | Friedemann Kleint <Friedemann.Kleint@theqtcompany.com> | 2015-09-22 14:26:33 +0000 |
commit | 47ff3dcd087c1239e885439963f02bb8b53b19ed (patch) | |
tree | 01289a0d296a6193122dd8024132f39e55b156f7 /src/plugins/platforms/windows/qwindowsinputcontext.h | |
parent | d417f81f28039b9165780f937c08ac9b2b92127d (diff) |
Windows: Disable Windows input context when another context is used.
Remove QWindowsContext::instance() method and use
QPlatformIntegration::inputContext() with proper check instead.
Extract static method to disable Windows IME on a window
by associating a null context from QWindowsInputContext
and use that to disable the IME if another context is
in use.
Amends change b46fe39d940712c5d401e731e171a7ccfadfe648.
Change-Id: Icaad99d390cea5559167602ffbf994660d4717a5
Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
Diffstat (limited to 'src/plugins/platforms/windows/qwindowsinputcontext.h')
-rw-r--r-- | src/plugins/platforms/windows/qwindowsinputcontext.h | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/plugins/platforms/windows/qwindowsinputcontext.h b/src/plugins/platforms/windows/qwindowsinputcontext.h index 110986c20c..eb4e3a3faa 100644 --- a/src/plugins/platforms/windows/qwindowsinputcontext.h +++ b/src/plugins/platforms/windows/qwindowsinputcontext.h @@ -42,6 +42,7 @@ QT_BEGIN_NAMESPACE class QInputMethodEvent; +class QWindowsWindow; class QWindowsInputContext : public QPlatformInputContext { @@ -62,14 +63,14 @@ public: explicit QWindowsInputContext(); ~QWindowsInputContext(); + static void setWindowsImeEnabled(QWindowsWindow *platformWindow, bool enabled); + bool hasCapability(Capability capability) const Q_DECL_OVERRIDE; void reset() Q_DECL_OVERRIDE; void update(Qt::InputMethodQueries) Q_DECL_OVERRIDE; void invokeAction(QInputMethod::Action, int cursorPosition) Q_DECL_OVERRIDE; void setFocusObject(QObject *object) Q_DECL_OVERRIDE; - static QWindowsInputContext *instance(); - bool startComposition(HWND hwnd); bool composition(HWND hwnd, LPARAM lParam); bool endComposition(HWND hwnd); |