changeset 4938:2af0032520d8

Fixed compiling on Android
author Sam Lantinga <slouken@libsdl.org>
date Fri, 31 Dec 2010 16:51:03 -0800
parents 24d44c7c4c63
children de89a6f73c06
files src/video/android/SDL_androidevents.c
diffstat 1 files changed, 5 insertions(+), 12 deletions(-) [+]
line wrap: on
line diff
--- a/src/video/android/SDL_androidevents.c	Fri Dec 31 08:50:06 2010 -0800
+++ b/src/video/android/SDL_androidevents.c	Fri Dec 31 16:51:03 2010 -0800
@@ -32,20 +32,13 @@
 
 #include "SDL_androidevents.h"
 
-void Android_InitEvents(){
-
-    SDL_Keyboard keyboard;
-
-    SDL_zero(keyboard);
-    SDL_AddKeyboard(&keyboard, -1);
-
+void Android_InitEvents()
+{
     SDLKey keymap[SDL_NUM_SCANCODES];
 
     /* Add default scancode to key mapping */
     SDL_GetDefaultKeymap(keymap);
-    SDL_SetKeymap(0, 0, keymap, SDL_NUM_SCANCODES);
-
-
+    SDL_SetKeymap(0, keymap, SDL_NUM_SCANCODES);
 }
 
 void
@@ -74,12 +67,12 @@
 
 int
 Android_OnKeyDown(int keycode){
-    return SDL_SendKeyboardKey(0, SDL_PRESSED, (SDL_scancode)keycode);
+    return SDL_SendKeyboardKey(SDL_PRESSED, (SDL_scancode)keycode);
 }
 
 int
 Android_OnKeyUp(int keycode){
-    return SDL_SendKeyboardKey(0, SDL_RELEASED, (SDL_scancode)keycode);
+    return SDL_SendKeyboardKey(SDL_RELEASED, (SDL_scancode)keycode);
 }
 
 /* vi: set ts=4 sw=4 expandtab: */