RG600 dpad is a hat.
This commit is contained in:
parent
6be1cc3159
commit
608ee03018
1 changed files with 4 additions and 4 deletions
|
@ -42,10 +42,10 @@ index 92d1a01..db4fec4 100644
|
|||
// Button events
|
||||
-#if defined(DEVICE_RG351P)
|
||||
+#if defined(DEVICE_handheld)
|
||||
+ #define BUTTON_PRESSED_UP event.type == SDL_JOYBUTTONDOWN && event.jbutton.button == 13
|
||||
+ #define BUTTON_PRESSED_DOWN event.type == SDL_JOYBUTTONDOWN && event.jbutton.button == 14
|
||||
+ #define BUTTON_PRESSED_LEFT event.type == SDL_JOYBUTTONDOWN && event.jbutton.button == 15
|
||||
+ #define BUTTON_PRESSED_RIGHT event.type == SDL_JOYBUTTONDOWN && event.jbutton.button == 16
|
||||
+ #define BUTTON_PRESSED_UP event.type == SDL_JOYBUTTONDOWN && event.jhat.value == SDL_HAT_UP
|
||||
+ #define BUTTON_PRESSED_DOWN event.type == SDL_JOYBUTTONDOWN && event.jhat.value == SDL_HAT_DOWN
|
||||
+ #define BUTTON_PRESSED_LEFT event.type == SDL_JOYBUTTONDOWN && event.jhat.value == SDL_HAT_LEFT
|
||||
+ #define BUTTON_PRESSED_RIGHT event.type == SDL_JOYBUTTONDOWN && event.jhat.value == SDL_HAT_RIGHT
|
||||
+ #define BUTTON_PRESSED_PAGEUP event.type == SDL_JOYBUTTONDOWN && (event.jbutton.button == 4 || event.jbutton.button == 6)
|
||||
+ #define BUTTON_PRESSED_PAGEDOWN event.type == SDL_JOYBUTTONDOWN && (event.jbutton.button == 5 || event.jbutton.button == 7)
|
||||
+ #define BUTTON_PRESSED_VALIDATE event.type == SDL_JOYBUTTONDOWN && event.jbutton.button == 1
|
Loading…
Reference in a new issue