diff options
author | Nicolas Fella <nicolas.fella@kde.org> | 2024-01-24 01:39:24 +0100 |
---|---|---|
committer | Qt Cherry-pick Bot <cherrypick_bot@qt-project.org> | 2024-02-01 02:58:36 +0000 |
commit | bec69733f67e65de456e63db600f4e871ae2b53b (patch) | |
tree | 8d802fee71d7765caffc788762c640c5ea557fb2 | |
parent | d74be7909a55988cb8c36430f1482f65e0a73345 (diff) |
Client: Fix Qt::KeypadModifier for key events
Use the right QXkbCommon::modifiers overload that can resolve the
modifier.
f614fdfa5dc522f805c7c061535df6a0dc7409b9 did this for wayland-server,
do the same for the client side
Pick-to: 6.6 6.5
Change-Id: Iff0c105cb31201241d4972a7772cf997cede3fc3
Reviewed-by: Liang Qi <liang.qi@qt.io>
(cherry picked from commit 17e46725c5971a3067d5abd5506fde6c03d0935f)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
-rw-r--r-- | src/client/qwaylandinputdevice.cpp | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/client/qwaylandinputdevice.cpp b/src/client/qwaylandinputdevice.cpp index f52789fdc..2a04f6011 100644 --- a/src/client/qwaylandinputdevice.cpp +++ b/src/client/qwaylandinputdevice.cpp @@ -1336,8 +1336,7 @@ void QWaylandInputDevice::Keyboard::keyboard_key(uint32_t serial, uint32_t time, auto code = key + 8; // map to wl_keyboard::keymap_format::keymap_format_xkb_v1 xkb_keysym_t sym = xkb_state_key_get_one_sym(mXkbState.get(), code); - - Qt::KeyboardModifiers modifiers = mParent->modifiers(); + Qt::KeyboardModifiers modifiers = QXkbCommon::modifiers(mXkbState.get(), sym); int qtkey = keysymToQtKey(sym, modifiers, mXkbState.get(), code); QString text = QXkbCommon::lookupString(mXkbState.get(), code); |