Mercurial > sdl-ios-xcode
comparison src/video/x11/SDL_x11events.c @ 2997:e4f025078c1c
indent
author | Sam Lantinga <slouken@libsdl.org> |
---|---|
date | Sun, 04 Jan 2009 23:41:09 +0000 |
parents | 2fad80c77c17 |
children | 699d68ef2aca |
comparison
equal
deleted
inserted
replaced
2996:972a69e47cd9 | 2997:e4f025078c1c |
---|---|
290 data = (X11_MouseData *) mouse->driverdata; | 290 data = (X11_MouseData *) mouse->driverdata; |
291 if (!data) { | 291 if (!data) { |
292 switch (xevent.type) { | 292 switch (xevent.type) { |
293 case MotionNotify: | 293 case MotionNotify: |
294 #ifdef DEBUG_MOTION | 294 #ifdef DEBUG_MOTION |
295 printf("X11 motion: %d,%d\n", xevent.xmotion.x, xevent.xmotion.y); | 295 printf("X11 motion: %d,%d\n", xevent.xmotion.x, |
296 #endif | 296 xevent.xmotion.y); |
297 SDL_SendMouseMotion(mouse->id, 0, xevent.xmotion.x, xevent.xmotion.y, 0); | 297 #endif |
298 SDL_SendMouseMotion(mouse->id, 0, xevent.xmotion.x, | |
299 xevent.xmotion.y, 0); | |
298 break; | 300 break; |
299 | 301 |
300 case ButtonPress: | 302 case ButtonPress: |
301 SDL_SendMouseButton(mouse->id, SDL_PRESSED, xevent.xbutton.button); | 303 SDL_SendMouseButton(mouse->id, SDL_PRESSED, |
304 xevent.xbutton.button); | |
302 break; | 305 break; |
303 | 306 |
304 case ButtonRelease: | 307 case ButtonRelease: |
305 SDL_SendMouseButton(mouse->id, SDL_RELEASED, xevent.xbutton.button); | 308 SDL_SendMouseButton(mouse->id, SDL_RELEASED, |
309 xevent.xbutton.button); | |
306 break; | 310 break; |
307 } | 311 } |
308 continue; | 312 continue; |
309 } | 313 } |
310 | 314 |