[quake3-commits] r2137 - trunk/code/sdl

DONOTREPLY at icculus.org DONOTREPLY at icculus.org
Fri Aug 5 15:47:34 EDT 2011


Author: ztm
Date: 2011-08-05 15:47:33 -0400 (Fri, 05 Aug 2011)
New Revision: 2137

Modified:
   trunk/code/sdl/sdl_input.c
Log:
Don't grab mouse till UI loads.

Modified: trunk/code/sdl/sdl_input.c
===================================================================
--- trunk/code/sdl/sdl_input.c	2011-08-05 16:19:01 UTC (rev 2136)
+++ trunk/code/sdl/sdl_input.c	2011-08-05 19:47:33 UTC (rev 2137)
@@ -1050,16 +1050,8 @@
 	SDL_EnableKeyRepeat( SDL_DEFAULT_REPEAT_DELAY, SDL_DEFAULT_REPEAT_INTERVAL );
 	keyRepeatEnabled = qtrue;
 
-	if( in_mouse->value )
-	{
-		mouseAvailable = qtrue;
-		IN_ActivateMouse( );
-	}
-	else
-	{
-		IN_DeactivateMouse( );
-		mouseAvailable = qfalse;
-	}
+	mouseAvailable = ( in_mouse->value != 0 );
+	IN_DeactivateMouse( );
 
 	appState = SDL_GetAppState( );
 	Cvar_SetValue( "com_unfocused",	!( appState & SDL_APPINPUTFOCUS ) );



More information about the quake3-commits mailing list