r1428 - trunk/code/sdl

DONOTREPLY at icculus.org DONOTREPLY at icculus.org
Wed Jul 16 13:45:10 EDT 2008


Author: tma
Date: 2008-07-16 13:45:10 -0400 (Wed, 16 Jul 2008)
New Revision: 1428

Modified:
   trunk/code/sdl/sdl_input.c
Log:
* Revert r1341 as there doesn't seem to be a lot of point to the change and it
  potentially will cause input events to be queued in a different order to that
  in which they were received


Modified: trunk/code/sdl/sdl_input.c
===================================================================
--- trunk/code/sdl/sdl_input.c	2008-07-16 07:15:09 UTC (rev 1427)
+++ trunk/code/sdl/sdl_input.c	2008-07-16 17:45:10 UTC (rev 1428)
@@ -653,7 +653,6 @@
 	SDL_Event e;
 	const char *p = NULL;
 	int key = 0;
-	int mx = 0, my = 0;
 
 	if( !SDL_WasInit( SDL_INIT_VIDEO ) )
 			return;
@@ -694,10 +693,7 @@
 
 			case SDL_MOUSEMOTION:
 				if (mouseActive)
-				{
-					mx += e.motion.xrel;
-					my += e.motion.yrel;
-				}
+					Com_QueueEvent( 0, SE_MOUSE, e.motion.xrel, e.motion.yrel, 0, NULL );
 				break;
 
 			case SDL_MOUSEBUTTONDOWN:
@@ -737,9 +733,6 @@
 				break;
 		}
 	}
-
-	if(mx || my)
-		Com_QueueEvent( 0, SE_MOUSE, mx, my, 0, NULL );
 }
 
 /*




More information about the quake3-commits mailing list