diff options
author | Paul Olav Tvete <paul.tvete@qt.io> | 2017-03-13 13:50:39 +0100 |
---|---|---|
committer | Paul Olav Tvete <paul.tvete@qt.io> | 2017-03-13 13:51:33 +0100 |
commit | dfcda81c5b13ad15517a37bcc45f3bf5f550466c (patch) | |
tree | f765a484186ad629aea0c3dbba94e4097a5b68aa /src/compositor/compositor_api | |
parent | e2805ef5438117b7828fef33876049c4c00868d2 (diff) | |
parent | 3d8b3113c2349b5e002ece39ff20118b471aac6e (diff) |
Merge remote-tracking branch 'origin/5.8' into 5.9
Change-Id: I76be82a6da77f51f6d53239d593dc6f61951559b
Diffstat (limited to 'src/compositor/compositor_api')
-rw-r--r-- | src/compositor/compositor_api/qwaylandkeyboard.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/compositor/compositor_api/qwaylandkeyboard.cpp b/src/compositor/compositor_api/qwaylandkeyboard.cpp index 55381b450..986f819ff 100644 --- a/src/compositor/compositor_api/qwaylandkeyboard.cpp +++ b/src/compositor/compositor_api/qwaylandkeyboard.cpp @@ -175,7 +175,11 @@ void QWaylandKeyboardPrivate::keyboard_release(wl_keyboard::Resource *resource) void QWaylandKeyboardPrivate::keyEvent(uint code, uint32_t state) { +#if QT_CONFIG(xkbcommon_evdev) uint key = toWaylandXkbV1Key(code); +#else + uint key = code; +#endif if (state == WL_KEYBOARD_KEY_STATE_PRESSED) { keys << key; } else { @@ -187,7 +191,11 @@ void QWaylandKeyboardPrivate::sendKeyEvent(uint code, uint32_t state) { uint32_t time = compositor()->currentTimeMsecs(); uint32_t serial = compositor()->nextSerial(); +#if QT_CONFIG(xkbcommon_evdev) uint key = toWaylandXkbV1Key(code); +#else + uint key = code; +#endif if (focusResource) send_key(focusResource->handle, serial, time, key, state); } |