Mercurial > sdl-ios-xcode
diff src/video/x11/SDL_x11video.c @ 3772:9087a84cba51 gsoc2008_manymouse
First comments and code upgrades in X11
author | Szymon Wilczek <kazeuser@gmail.com> |
---|---|
date | Sat, 02 Aug 2008 17:40:49 +0000 |
parents | 2970fcfbdd54 |
children | 3b5691f85c0d |
line wrap: on
line diff
--- a/src/video/x11/SDL_x11video.c Sat Aug 02 14:02:28 2008 +0000 +++ b/src/video/x11/SDL_x11video.c Sat Aug 02 17:40:49 2008 +0000 @@ -27,14 +27,15 @@ #include "../SDL_pixels_c.h" #include "SDL_x11video.h" -//#include "SDL_d3drender.h" -//#include "SDL_gdirender.h" +/*#include "SDL_d3drender.h" +#include "SDL_gdirender.h"*/ XDevice **SDL_XDevices; int SDL_NumOfXDevices; XEventClass SDL_XEvents[256]; int SDL_NumOfXEvents; -int motion, button_pressed, button_released; + +int motion, button_pressed, button_released;/*the definitions of the mice events*/ int proximity_in, proximity_out; /* Initialization/Query functions */ @@ -249,6 +250,7 @@ return -1; } X11_InitMouse(_this); + /*we're generating the table of events that should be recognized*/ for(i=0;i<SDL_NumOfXDevices;++i) { DeviceKeyPress(SDL_XDevices[i],c_not_needed,xEvent); @@ -256,13 +258,13 @@ DeviceKeyRelease(SDL_XDevices[i],c_not_needed,xEvent); if (xEvent) SDL_XEvents[index++] = xEvent; - /* focus events */ + /*focus events*/ DeviceFocusIn(SDL_XDevices[i],c_not_needed,xEvent); if (xEvent) SDL_XEvents[index++] = xEvent; DeviceFocusOut(SDL_XDevices[i],c_not_needed,xEvent); if (xEvent) SDL_XEvents[index++] = xEvent; - /* button events */ + /*button events*/ DeviceButtonPress(SDL_XDevices[i],c_not_needed,xEvent); if (xEvent) { @@ -276,7 +278,7 @@ button_released=c_not_needed; } - /* proximity events */ + /*proximity events*/ ProximityIn(SDL_XDevices[i],c_not_needed,xEvent); if (xEvent) { @@ -289,7 +291,7 @@ SDL_XEvents[index++] = xEvent; proximity_out=c_not_needed; } - /* motion events */ + /*motion events*/ DeviceMotionNotify(SDL_XDevices[i],c_not_needed,xEvent); if (xEvent) { @@ -297,7 +299,7 @@ motion=c_not_needed; } - /* device state */ + /*device state*/ DeviceStateNotify(SDL_XDevices[i],c_not_needed,xEvent); if (xEvent) SDL_XEvents[index++] = xEvent; DeviceMappingNotify(SDL_XDevices[i], @@ -313,7 +315,7 @@ if (xEvent) SDL_XEvents[index++] = xEvent; #endif - /* button motion */ + /*button motion*/ DeviceButtonMotion(SDL_XDevices[i], c_not_needed,xEvent); if (xEvent) SDL_XEvents[index++] = xEvent;