summaryrefslogtreecommitdiffstats
path: root/input/joystick.h
diff options
context:
space:
mode:
authorUoti Urpala <uau@mplayer2.org>2011-04-25 09:43:59 +0300
committerUoti Urpala <uau@mplayer2.org>2011-05-02 00:43:31 +0300
commit23cb82907220d0c2724a0ec92bde437cbcd67d6a (patch)
tree1c1ea8667a2da5b6ddb5dd8e2f0c6f6558304ab5 /input/joystick.h
parent3e86228fad309b54869bf2a3314756933ba74e43 (diff)
downloadmpv-23cb82907220d0c2724a0ec92bde437cbcd67d6a.tar.bz2
mpv-23cb82907220d0c2724a0ec92bde437cbcd67d6a.tar.xz
input: move all key code lists to input/keycodes.h
Move the definitions of all special key codes (those not passed by ASCII value) to input/keycodes.h. Before they were spread between osdep/keycodes.h, input/joystick.h, input/mouse.h and input/ar.h, plus some special values in input.h. This was especially inconvenient as the codes had to be coordinated to not conflict between the files. The change requires a bit of ugliness as appleir.c includes <linux/input.h> which contains various conflicting KEY_* definitions. Work around this by adding a special preprocessor variable which can be used to avoid defining these in keycodes.h.
Diffstat (limited to 'input/joystick.h')
-rw-r--r--input/joystick.h34
1 files changed, 0 insertions, 34 deletions
diff --git a/input/joystick.h b/input/joystick.h
index 996f0fed21..b9480eb686 100644
--- a/input/joystick.h
+++ b/input/joystick.h
@@ -19,40 +19,6 @@
#ifndef MPLAYER_JOYSTICK_H
#define MPLAYER_JOYSTICK_H
-#define JOY_BASE (0x100+128)
-#define JOY_AXIS0_PLUS (JOY_BASE+0)
-#define JOY_AXIS0_MINUS (JOY_BASE+1)
-#define JOY_AXIS1_PLUS (JOY_BASE+2)
-#define JOY_AXIS1_MINUS (JOY_BASE+3)
-#define JOY_AXIS2_PLUS (JOY_BASE+4)
-#define JOY_AXIS2_MINUS (JOY_BASE+5)
-#define JOY_AXIS3_PLUS (JOY_BASE+6)
-#define JOY_AXIS3_MINUS (JOY_BASE+7)
-#define JOY_AXIS4_PLUS (JOY_BASE+8)
-#define JOY_AXIS4_MINUS (JOY_BASE+9)
-#define JOY_AXIS5_PLUS (JOY_BASE+10)
-#define JOY_AXIS5_MINUS (JOY_BASE+11)
-#define JOY_AXIS6_PLUS (JOY_BASE+12)
-#define JOY_AXIS6_MINUS (JOY_BASE+13)
-#define JOY_AXIS7_PLUS (JOY_BASE+14)
-#define JOY_AXIS7_MINUS (JOY_BASE+15)
-#define JOY_AXIS8_PLUS (JOY_BASE+16)
-#define JOY_AXIS8_MINUS (JOY_BASE+17)
-#define JOY_AXIS9_PLUS (JOY_BASE+18)
-#define JOY_AXIS9_MINUS (JOY_BASE+19)
-
-#define JOY_BTN_BASE ((0x100+148)|MP_NO_REPEAT_KEY)
-#define JOY_BTN0 (JOY_BTN_BASE+0)
-#define JOY_BTN1 (JOY_BTN_BASE+1)
-#define JOY_BTN2 (JOY_BTN_BASE+2)
-#define JOY_BTN3 (JOY_BTN_BASE+3)
-#define JOY_BTN4 (JOY_BTN_BASE+4)
-#define JOY_BTN5 (JOY_BTN_BASE+5)
-#define JOY_BTN6 (JOY_BTN_BASE+6)
-#define JOY_BTN7 (JOY_BTN_BASE+7)
-#define JOY_BTN8 (JOY_BTN_BASE+8)
-#define JOY_BTN9 (JOY_BTN_BASE+9)
-
int mp_input_joystick_init(char* dev);
int mp_input_joystick_read(void *ctx, int fd);