Mercurial > sdl-ios-xcode
diff src/video/android/SDL_androidvideo.c @ 5001:77df56570442
Added "mouse" support for the Android touch screen
author | Sam Lantinga <slouken@libsdl.org> |
---|---|
date | Thu, 13 Jan 2011 18:31:15 -0800 |
parents | a514bfe6952a |
children | b530ef003506 |
line wrap: on
line diff
--- a/src/video/android/SDL_androidvideo.c Thu Jan 13 18:03:56 2011 -0800 +++ b/src/video/android/SDL_androidvideo.c Thu Jan 13 18:31:15 2011 -0800 @@ -29,6 +29,7 @@ #include "../SDL_sysvideo.h" #include "../SDL_pixels_c.h" #include "../../events/SDL_events_c.h" +#include "../../events/SDL_windowevents_c.h" #include "SDL_androidvideo.h" #include "SDL_androidevents.h" @@ -63,6 +64,8 @@ int Android_ScreenHeight = 0; Uint32 Android_ScreenFormat = SDL_PIXELFORMAT_UNKNOWN; +/* Currently only one window */ +SDL_Window *Android_Window = NULL; static int Android_Available(void) @@ -158,6 +161,10 @@ Android_ScreenWidth = width; Android_ScreenHeight = height; Android_ScreenFormat = format; + + if (Android_Window) { + SDL_SendWindowEvent(Android_Window, SDL_WINDOWEVENT_RESIZED, width, height); + } } /* vi: set ts=4 sw=4 expandtab: */