diff options
Diffstat (limited to 'hw/xfree86/utils/xorgcfg/keyboard-cfg.c')
-rw-r--r-- | hw/xfree86/utils/xorgcfg/keyboard-cfg.c | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/hw/xfree86/utils/xorgcfg/keyboard-cfg.c b/hw/xfree86/utils/xorgcfg/keyboard-cfg.c index b8697c11f..b93066e6c 100644 --- a/hw/xfree86/utils/xorgcfg/keyboard-cfg.c +++ b/hw/xfree86/utils/xorgcfg/keyboard-cfg.c @@ -159,7 +159,8 @@ KeyboardConfig(XtPointer config) XF86ConfInputPtr key = XF86Config->conf_input_lst; while (key != NULL) { - if (strcasecmp(key->inp_driver, "keyboard") == 0 && + if (((strcasecmp(key->inp_driver, "keyboard") == 0) || + (strcasecmp(key->inp_driver, "kbd") == 0)) && xkb_infos[i]->conf == key) break; key = (XF86ConfInputPtr)(key->list.next); @@ -216,7 +217,8 @@ KeyboardConfig(XtPointer config) int nkeyboards = 0; while (input != NULL) { - if (strcasecmp(input->inp_driver, "keyboard") == 0) + if ((strcasecmp(input->inp_driver, "keyboard") == 0) || + (strcasecmp(input->inp_driver, "kbd") == 0)) ++nkeyboards; input = (XF86ConfInputPtr)(input->list.next); } @@ -253,7 +255,11 @@ KeyboardConfig(XtPointer config) keyboard = XtNew(XF86ConfInputRec); keyboard->list.next = NULL; keyboard->inp_identifier = XtNewString(ident_string); +#if defined(USE_DEPRECATED_KEYBOARD_DRIVER) keyboard->inp_driver = XtNewString("keyboard"); +#else + keyboard->inp_driver = XtNewString("kbd"); +#endif keyboard->inp_option_lst = xf86newOption(XtNewString(XkbRules), XtNewString(rules)); xf86addNewOption(keyboard->inp_option_lst, @@ -493,7 +499,8 @@ InitializeKeyboard(void) /* XXX Assumes the first keyboard is the core keyboard */ while (keyboard != NULL) { - if (strcasecmp(keyboard->inp_driver, "keyboard") == 0) + if ((strcasecmp(keyboard->inp_driver, "keyboard") == 0) || + (strcasecmp(keyboard->inp_driver, "kbd") == 0)) break; keyboard = (XF86ConfInputPtr)(keyboard->list.next); } |