vid_sdl.c: Removed some stupid includes, some whitespace

vid_sgl.c: Added freelook and joystick support.
This commit is contained in:
Jeff Teunissen 2000-10-13 06:16:27 +00:00
parent 8903d650d2
commit fd81937dd9
2 changed files with 62 additions and 56 deletions

View file

@ -30,34 +30,23 @@
#include "config.h"
#endif
#include "SDL.h"
#include <SDL.h>
#include "bothdefs.h" // needed by: common.h, net.h, client.
#include "quakedef.h"
#include "menu.h"
#include "vid.h"
#include "sys.h"
#include "mathlib.h" // needed by: protocol.h, render.h, client.h,
// modelgen.h, glmodel.h
#include "wad.h"
#include "draw.h"
#include "cvar.h"
#include "net.h" // needed by: client.h
#include "protocol.h" // needed by: client.h
#include "cmd.h"
#include "keys.h"
#include "sbar.h"
#include "sound.h"
#include "render.h" // needed by: client.h, gl_model.h, glquake.h
#include "client.h" // need cls in this file
#include "client.h"
#include "console.h"
#include "qendian.h"
#include "qargs.h"
#include "compat.h"
#include "cvar.h"
#include "draw.h"
#include "d_iface.h"
#include "d_local.h"
#include "input.h"
#include "joystick.h"
#include "keys.h"
#include "menu.h"
#include "sys.h"
#include "qargs.h"
#include "qendian.h"
#include "qtypes.h"
#include "quakedef.h"
cvar_t *_windowed_mouse;
@ -443,12 +432,15 @@ IN_Commands (void)
JOY_Command ();
if (old_windowed_mouse != _windowed_mouse->int_val) {
old_windowed_mouse = _windowed_mouse->value;
old_windowed_mouse = _windowed_mouse->int_val;
if (_windowed_mouse->int_val)
if (_windowed_mouse->int_val) { // grab the pointer
SDL_ShowCursor (0);
SDL_WM_GrabInput (SDL_GRAB_ON);
else
} else { // ungrab the pointer
SDL_WM_GrabInput (SDL_GRAB_OFF);
SDL_ShowCursor (1);
}
}
}