mirror of
https://github.com/labwc/labwc.git
synced 2025-11-03 09:01:51 -05:00
keyboard: use 'us' as fallback for XKB_DEFAULT_LAYOUT
...if keymap cannot be created for the provided XKB_DEFAULT_LAYOUT. If keymap still cannot be created, exit with a helpful message to avoid crash that is hard to understand. Fixes: https://github.com/stefonarch/lxqt-labwc-session/issues/7
This commit is contained in:
parent
1e1e90d0bb
commit
5cb3583108
2 changed files with 17 additions and 1 deletions
|
|
@ -296,6 +296,11 @@ new_keyboard(struct seat *seat, struct wlr_input_device *device, bool virtual)
|
|||
keyboard->wlr_keyboard = kb;
|
||||
keyboard->is_virtual = virtual;
|
||||
|
||||
if (!seat->keyboard_group->keyboard.keymap) {
|
||||
wlr_log(WLR_ERROR, "cannot set keymap");
|
||||
exit(EXIT_FAILURE);
|
||||
}
|
||||
|
||||
wlr_keyboard_set_keymap(kb, seat->keyboard_group->keyboard.keymap);
|
||||
|
||||
/*
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue