patch-2.2.19 linux/drivers/usb/keybdev.c
Next file: linux/drivers/usb/printer.c
Previous file: linux/drivers/usb/hub.h
Back to the patch index
Back to the overall index
- Lines: 42
- Date:
Sun Mar 25 11:37:37 2001
- Orig file:
v2.2.18/drivers/usb/keybdev.c
- Orig date:
Sun Mar 25 11:28:32 2001
diff -u --new-file --recursive --exclude-from /usr/src/exclude v2.2.18/drivers/usb/keybdev.c linux/drivers/usb/keybdev.c
@@ -60,6 +60,7 @@
};
#ifdef CONFIG_INPUT_ADBHID
+#ifdef CONFIG_MAC_ADBKEYCODES
extern int mac_hid_keyboard_sends_linux_keycodes(void);
static unsigned char mac_keycodes[256] = {
@@ -76,19 +77,20 @@
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 94, 0, 93, 0, 0, 0, 0, 0, 0,104,102
};
-
-#ifdef CONFIG_INPUT_MOUSEDEV
+#endif /* CONFIG_MAC_ADBKEYCODES */
+#ifdef CONFIG_MAC_EMUMOUSEBTN
extern int mac_hid_mouse_emulate_buttons(int, unsigned int, int);
-#endif /* CONFIG_INPUT_MOUSEDEV */
+#endif /* CONFIG_MAC_EMUMOUSEBTN */
#endif /* CONFIG_INPUT_ADBHID */
static int emulate_raw(unsigned int keycode, int down)
{
#ifdef CONFIG_INPUT_ADBHID
-#ifdef CONFIG_INPUT_MOUSEDEV
+#ifdef CONFIG_MAC_EMUMOUSEBTN
if (mac_hid_mouse_emulate_buttons(1, keycode, down))
return 0;
-#endif /* CONFIG_INPUT_MOUSEDEV */
+#endif /* CONFIG_MAC_EMUMOUSEBTN */
+#ifdef CONFIG_MAC_ADBKEYCODES
if (!mac_hid_keyboard_sends_linux_keycodes()) {
if (keycode > 255 || !mac_keycodes[keycode])
return -1;
@@ -97,6 +99,7 @@
return 0;
}
+#endif /* CONFIG_MAC_ADBKEYCODES */
#endif /* CONFIG_INPUT_ADBHID */
if (keycode > 255 || !x86_keycodes[keycode])
return -1;
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)