summaryrefslogtreecommitdiffstats
path: root/games/rottdc/files/patch-rt__in.c
blob: 30d3b4b7c4cb41f1d7415db8137e24df6a942a5b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
--- rt_in.c.orig	Wed Feb 18 08:30:12 2004
+++ rt_in.c	Wed Feb 18 08:54:20 2004
@@ -665,14 +665,16 @@
 
    {
    int buttons = 0;
+#if USE_SDL
+   int bmask, i;
+   const static int tbl[] = {SDL_BUTTON_LEFT,SDL_BUTTON_RIGHT,SDL_BUTTON_MIDDLE,SDL_BUTTON_WHEELUP,SDL_BUTTON_WHEELDOWN};
+#endif
 
    IN_PumpEvents();
 
 #if USE_SDL
 #if 1
-	int bmask = SDL_GetMouseState(NULL,NULL);
-	int i;
-	const static int tbl[] = {SDL_BUTTON_LEFT,SDL_BUTTON_RIGHT,SDL_BUTTON_MIDDLE,SDL_BUTTON_WHEELUP,SDL_BUTTON_WHEELDOWN};
+	bmask = SDL_GetMouseState(NULL,NULL);
 	for(i=0;i<sizeof(tbl);i++) {
 		if (bmask & SDL_BUTTON(tbl[i])) buttons|=1<<i;
 	}
OpenPOWER on IntegriCloud