From 178544362e4b5e1320a24d28c6cc7a4c7221b199 Mon Sep 17 00:00:00 2001 From: Jonathan Gray Date: Wed, 1 May 2013 23:38:21 +1000 Subject: [PATCH] avoid enum to int conversions --- code/sdl/sdl_input.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/code/sdl/sdl_input.cpp b/code/sdl/sdl_input.cpp index 5e0e4ac..6231dd0 100644 --- a/code/sdl/sdl_input.cpp +++ b/code/sdl/sdl_input.cpp @@ -77,7 +77,7 @@ static int vidRestartTime = 0; IN_PrintKey =============== */ -static void IN_PrintKey( const SDL_keysym *keysym, fakeAscii_t key, qboolean down ) +static void IN_PrintKey( const SDL_keysym *keysym, int key, qboolean down ) { if( down ) Com_Printf( "+ " ); @@ -120,7 +120,7 @@ static void IN_PrintKey( const SDL_keysym *keysym, fakeAscii_t key, qboolean dow IN_IsConsoleKey =============== */ -static qboolean IN_IsConsoleKey( fakeAscii_t key, const unsigned char character ) +static qboolean IN_IsConsoleKey( int key, const unsigned char character ) { typedef struct consoleKey_s { @@ -132,7 +132,7 @@ static qboolean IN_IsConsoleKey( fakeAscii_t key, const unsigned char character union { - fakeAscii_t key; + int key; unsigned char character; } u; } consoleKey_t; @@ -212,7 +212,7 @@ IN_TranslateSDLToQ3Key =============== */ static const char *IN_TranslateSDLToQ3Key( SDL_keysym *keysym, - fakeAscii_t *key, qboolean down ) + int *key, qboolean down ) { static unsigned char buf[ 2 ] = { '\0', '\0' }; @@ -878,7 +878,7 @@ static void IN_ProcessEvents( void ) { SDL_Event e; const char *character = NULL; - fakeAscii_t key = 0; + int key = 0; if( !SDL_WasInit( SDL_INIT_VIDEO ) ) return;