Merge pull request #75461 from Sabrehull/keycode-fix
[X11] Fix layout bug in `keyboard_get_keycode_from_physical`
This commit is contained in:
commit
80528c17c7
1 changed files with 1 additions and 1 deletions
|
@ -2848,7 +2848,7 @@ Key DisplayServerX11::keyboard_get_keycode_from_physical(Key p_keycode) const {
|
||||||
Key modifiers = p_keycode & KeyModifierMask::MODIFIER_MASK;
|
Key modifiers = p_keycode & KeyModifierMask::MODIFIER_MASK;
|
||||||
Key keycode_no_mod = p_keycode & KeyModifierMask::CODE_MASK;
|
Key keycode_no_mod = p_keycode & KeyModifierMask::CODE_MASK;
|
||||||
unsigned int xkeycode = KeyMappingX11::get_xlibcode(keycode_no_mod);
|
unsigned int xkeycode = KeyMappingX11::get_xlibcode(keycode_no_mod);
|
||||||
KeySym xkeysym = XkbKeycodeToKeysym(x11_display, xkeycode, 0, 0);
|
KeySym xkeysym = XkbKeycodeToKeysym(x11_display, xkeycode, keyboard_get_current_layout(), 0);
|
||||||
if (is_ascii_lower_case(xkeysym)) {
|
if (is_ascii_lower_case(xkeysym)) {
|
||||||
xkeysym -= ('a' - 'A');
|
xkeysym -= ('a' - 'A');
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue