diff src/video/x11/SDL_x11events.c @ 4655:4c94f2023d62

Fixed bugs in input, cleaned up $1
author Jim Grandpre <jim.tla@gmail.com>
date Fri, 18 Jun 2010 01:43:02 -0400
parents eea1bf53effa
children 03dcb795c583
line wrap: on
line diff
--- a/src/video/x11/SDL_x11events.c	Thu Jun 17 03:41:27 2010 -0400
+++ b/src/video/x11/SDL_x11events.c	Fri Jun 18 01:43:02 2010 -0400
@@ -463,14 +463,16 @@
 		    break;
 		case EV_SYN:
 		  //printf("Id: %i\n",touch->id); 
-		    if(data->x >= 0 || data->y >= 0)
-			SDL_SendTouchMotion(touch->id,data->finger, 
-					    SDL_FALSE,data->x,data->y,
+		  if(data->up) {
+		      SDL_SendFingerDown(touch->id,data->finger,
+			  	       SDL_FALSE,data->x,data->y,
+				       data->pressure);
+		  }
+		  else if(data->x >= 0 || data->y >= 0)
+		      SDL_SendTouchMotion(touch->id,data->finger, 
+					SDL_FALSE,data->x,data->y,
 					    data->pressure);
-		    if(data->up) 
-			SDL_SendFingerDown(touch->id,data->finger,
-					   SDL_FALSE,data->x,data->y,
-					   data->pressure);
+		  
 		    //printf("Synched: %i tx: %i, ty: %i\n",
 		    //	   data->finger,data->x,data->y);
 		    data->x = -1;