Pass extended key event infomation in xcb platform.
Bare QKeyEvent missing some useful info for input method. Use new construct of QKeyEvent to create extended QKeyEvent Change-Id: I8c89e80e7329b92e3e04d5fe52d07c6f6f9e006f Reviewed-by: Lars Knoll <lars.knoll@digia.com>
This commit is contained in:
parent
be6e270d12
commit
dccd784edf
@ -1102,7 +1102,7 @@ void QXcbKeyboard::handleKeyEvent(QWindow *window, QEvent::Type type, xcb_keycod
|
|||||||
|
|
||||||
bool filtered = false;
|
bool filtered = false;
|
||||||
if (inputContext) {
|
if (inputContext) {
|
||||||
QKeyEvent event(type, qtcode, modifiers, string, isAutoRepeat);
|
QKeyEvent event(type, qtcode, modifiers, code, sym, state, string.left(count), isAutoRepeat, count);
|
||||||
event.setTimestamp(time);
|
event.setTimestamp(time);
|
||||||
filtered = inputContext->filterEvent(&event);
|
filtered = inputContext->filterEvent(&event);
|
||||||
}
|
}
|
||||||
@ -1130,7 +1130,7 @@ void QXcbKeyboard::handleKeyEvent(QWindow *window, QEvent::Type type, xcb_keycod
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (!filtered && inputContext) {
|
if (!filtered && inputContext) {
|
||||||
QKeyEvent event(QEvent::KeyPress, qtcode, modifiers, string, isAutoRepeat);
|
QKeyEvent event(QEvent::KeyPress, qtcode, modifiers, code, sym, state, string.left(count), isAutoRepeat, count);
|
||||||
event.setTimestamp(time);
|
event.setTimestamp(time);
|
||||||
filtered = inputContext->filterEvent(&event);
|
filtered = inputContext->filterEvent(&event);
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user