diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 700e1c23d..01559d993 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -8,6 +8,8 @@ editor/med.c: Deleted unnecessary drop-to-shell feature; commented out unused Re main/bmread.c, main/hostage.c, main/piggy.h: Moved remove_char declaration to piggy.h - patch by Kp main/multi.h, main/net_udp.c: Moved multi_* declarations to multi.h - patch by Kp maths/rand.c: Included maths.h in rand.c to get d_rand prototype - patch by Kp +arch/include/joy.h, arch/sdl/event.c, arch/sdl/joy.c: Moved joy_*_handler declarations to joy.h - patch by Kp + 20121102 -------- diff --git a/arch/include/joy.h b/arch/include/joy.h index aa8dec7f4..b69293ea9 100644 --- a/arch/include/joy.h +++ b/arch/include/joy.h @@ -9,6 +9,7 @@ #include "pstypes.h" #include "fix.h" +#include struct d_event; @@ -25,5 +26,8 @@ extern void joy_close(); extern void event_joystick_get_axis(struct d_event *event, int *axis, int *value); extern void joy_flush(); extern int event_joystick_get_button(struct d_event *event); +extern void joy_button_handler(SDL_JoyButtonEvent *jbe); +extern void joy_hat_handler(SDL_JoyHatEvent *jhe); +extern int joy_axis_handler(SDL_JoyAxisEvent *jae); #endif // _JOY_H diff --git a/arch/sdl/event.c b/arch/sdl/event.c index 4b68aa478..ea40f8ac5 100644 --- a/arch/sdl/event.c +++ b/arch/sdl/event.c @@ -15,14 +15,11 @@ #include "timer.h" #include "config.h" -#include +#include "joy.h" extern void key_handler(SDL_KeyboardEvent *event); extern void mouse_button_handler(SDL_MouseButtonEvent *mbe); extern void mouse_motion_handler(SDL_MouseMotionEvent *mme); -extern void joy_button_handler(SDL_JoyButtonEvent *jbe); -extern void joy_hat_handler(SDL_JoyHatEvent *jhe); -extern int joy_axis_handler(SDL_JoyAxisEvent *jae); extern void mouse_cursor_autohide(); static int initialised=0; diff --git a/arch/sdl/joy.c b/arch/sdl/joy.c index 3a94acfba..d5e1da4bb 100644 --- a/arch/sdl/joy.c +++ b/arch/sdl/joy.c @@ -5,7 +5,6 @@ */ #include // for memset -#include #include "joy.h" #include "error.h"