QXkbCommon: Use isKeypad() to replace duplicate logic
This amends 298c950912
.
Pick-to: 6.6 6.5
Change-Id: I44696464817d6d3f6b1b3a7d005334805fb1cc38
Reviewed-by: Liang Qi <liang.qi@qt.io>
This commit is contained in:
parent
e6a0b6b3c9
commit
c524ca342b
@ -579,7 +579,7 @@ Qt::KeyboardModifiers QXkbCommon::modifiers(struct xkb_state *state, xkb_keysym_
|
||||
if (xkb_state_mod_name_is_active(state, XKB_MOD_NAME_LOGO, XKB_STATE_MODS_EFFECTIVE) > 0)
|
||||
modifiers |= Qt::MetaModifier;
|
||||
|
||||
if (keysym >= XKB_KEY_KP_Space && keysym <= XKB_KEY_KP_9)
|
||||
if (isKeypad(keysym))
|
||||
modifiers |= Qt::KeypadModifier;
|
||||
|
||||
return modifiers;
|
||||
|
Loading…
Reference in New Issue
Block a user