diff --git a/src/boards/transformer.cpp b/src/boards/transformer.cpp index 57246b83..81627fbc 100644 --- a/src/boards/transformer.cpp +++ b/src/boards/transformer.cpp @@ -23,7 +23,7 @@ static uint8 *WRAM=NULL; static uint32 WRAMSIZE; -unsigned int *GetKeyboard(void); // FIXME: not so much portable, don't know really how to solve this correctly here... +unsigned int *GetKeyboard(void); // FIXME: 10/28 - now implemented in SDL as well. should we rename this to a FCEUI_* function? static unsigned int *TransformerKeys, oldkeys[256]; static int TransformerCycleCount, TransformerChar = 0; diff --git a/src/drivers/sdl/input.cpp b/src/drivers/sdl/input.cpp index c75186e2..183d63bd 100644 --- a/src/drivers/sdl/input.cpp +++ b/src/drivers/sdl/input.cpp @@ -420,6 +420,16 @@ void FCEUD_LoadStateFrom () FCEUI_LoadState (fname.c_str ()); } +/** +* Hook for transformer board +*/ +unsigned int *GetKeyboard(void) +{ + int size = 256; + Uint8* keystate = SDL_GetKeyState(&size); + return (unsigned int*)(keystate); +} + /** * Parse keyboard commands and execute accordingly. */