mismatched ()s don't help.

This commit is contained in:
Bill Currie 2000-01-16 06:55:09 +00:00
parent b15fdf6acf
commit 22c0af3d0e
3 changed files with 20 additions and 20 deletions

View file

@ -47,7 +47,7 @@
int int
VID_CheckDGA(Display *dpy, int *maj_ver, int *min_ver, int *hasvideo) VID_CheckDGA(Display *dpy, int *maj_ver, int *min_ver, int *hasvideo)
{ {
#if defined(HAS_DGA) && defined(_EXPERIMENTAL_)) #if defined(HAS_DGA) && defined(_EXPERIMENTAL_)
int event_base, error_base, dgafeat, dummy; int event_base, error_base, dgafeat, dummy;
if (! XF86DGAQueryExtension(dpy, &event_base, &error_base)) { if (! XF86DGAQueryExtension(dpy, &event_base, &error_base)) {
@ -81,7 +81,7 @@ VID_CheckDGA(Display *dpy, int *maj_ver, int *min_ver, int *hasvideo)
int int
VID_CheckVMode(Display *dpy, int *maj_ver, int *min_ver) VID_CheckVMode(Display *dpy, int *maj_ver, int *min_ver)
{ {
#if (defined(HAS_DGA) && defined(_EXPERIMENTAL_)) #if defined(HAS_DGA) && defined(_EXPERIMENTAL_)
XF86VidModeModeInfo **vidmodes; XF86VidModeModeInfo **vidmodes;
int event_base, error_base; int event_base, error_base;
int dummy; int dummy;

View file

@ -32,7 +32,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
#include <X11/keysym.h> #include <X11/keysym.h>
#include <X11/cursorfont.h> #include <X11/cursorfont.h>
#if defined(HAS_DGA) && defined(_EXPERIMENTAL_)) #if defined(HAS_DGA) && defined(_EXPERIMENTAL_)
#include <X11/extensions/xf86dga.h> #include <X11/extensions/xf86dga.h>
#include <X11/extensions/xf86vmode.h> #include <X11/extensions/xf86vmode.h>
#endif #endif
@ -74,7 +74,7 @@ static float old_mouse_x, old_mouse_y;
static int mouse_grabbed = 0; static int mouse_grabbed = 0;
#define mouse_shouldgrab ((int)vid_glx_fullscreen.value ||(int)_windowed_mouse.value) #define mouse_shouldgrab ((int)vid_glx_fullscreen.value ||(int)_windowed_mouse.value)
#if defined(HAS_DGA) && defined(_EXPERIMENTAL_)) #if defined(HAS_DGA) && defined(_EXPERIMENTAL_)
static int nummodes; static int nummodes;
static XF86VidModeModeInfo **vidmodes; static XF86VidModeModeInfo **vidmodes;
static int hasdga = 0, hasdgavideo = 0, hasvidmode = 0; static int hasdga = 0, hasdgavideo = 0, hasvidmode = 0;
@ -171,7 +171,7 @@ do_grabs(int grab)
XGrabKeyboard(dpy, win, False, GrabModeAsync, GrabModeAsync, XGrabKeyboard(dpy, win, False, GrabModeAsync, GrabModeAsync,
CurrentTime); CurrentTime);
#if defined(HAS_DGA) && defined(_EXPERIMENTAL_)) #if defined(HAS_DGA) && defined(_EXPERIMENTAL_)
if (hasdga) { if (hasdga) {
XF86DGADirectVideo(dpy, screen, XF86DGADirectMouse); XF86DGADirectVideo(dpy, screen, XF86DGADirectMouse);
dgamouse = 1; dgamouse = 1;
@ -186,7 +186,7 @@ do_grabs(int grab)
/* /*
Release grab Release grab
*/ */
#if defined(HAS_DGA) && defined(_EXPERIMENTAL_)) #if defined(HAS_DGA) && defined(_EXPERIMENTAL_)
if (dgamouse) { if (dgamouse) {
XF86DGADirectVideo(dpy, screen, 0); XF86DGADirectVideo(dpy, screen, 0);
dgamouse = 0; dgamouse = 0;
@ -218,7 +218,7 @@ do_fullscreen(int full)
return; return;
} }
#endif #endif
#if defined(HAS_DGA) && defined(_EXPERIMENTAL_)) #if defined(HAS_DGA) && defined(_EXPERIMENTAL_)
if (hasvidmode) { if (hasvidmode) {
static int prev_x = 0, prev_y = 0, prev_w = 640, prev_h = 480; static int prev_x = 0, prev_y = 0, prev_w = 640, prev_h = 480;
@ -280,7 +280,7 @@ VID_Shutdown(void)
glXDestroyContext(dpy, ctx); glXDestroyContext(dpy, ctx);
ctx = NULL; ctx = NULL;
#if defined(HAS_DGA) && defined(_EXPERIMENTAL_)) #if defined(HAS_DGA) && defined(_EXPERIMENTAL_)
if (hasvidmode) { if (hasvidmode) {
int i; int i;
@ -532,7 +532,7 @@ void VID_Init(unsigned char *palette)
Cvar_RegisterVariable(&gl_ztrick); Cvar_RegisterVariable(&gl_ztrick);
Cvar_RegisterVariable(&_windowed_mouse); Cvar_RegisterVariable(&_windowed_mouse);
Cvar_RegisterVariable(&vid_glx_fullscreen); Cvar_RegisterVariable(&vid_glx_fullscreen);
#if defined(HAS_DGA) && defined(_EXPERIMENTAL_)) #if defined(HAS_DGA) && defined(_EXPERIMENTAL_)
Cvar_RegisterVariable(&vid_dga_mouseaccel); Cvar_RegisterVariable(&vid_dga_mouseaccel);
#endif #endif
@ -581,7 +581,7 @@ void VID_Init(unsigned char *palette)
exit(1); exit(1);
} }
#if defined(HAS_DGA) && defined(_EXPERIMENTAL_)) #if defined(HAS_DGA) && defined(_EXPERIMENTAL_)
{ {
int maj_ver; int maj_ver;
@ -815,7 +815,7 @@ GetEvent(void)
break; break;
case MotionNotify: case MotionNotify:
#if defined(HAS_DGA) && defined(_EXPERIMENTAL_)) #if defined(HAS_DGA) && defined(_EXPERIMENTAL_)
if (dgamouse) { if (dgamouse) {
mouse_x += (float)x_event.xmotion.x_root mouse_x += (float)x_event.xmotion.x_root
* vid_dga_mouseaccel.value; * vid_dga_mouseaccel.value;

View file

@ -74,7 +74,7 @@ static float old_mouse_x, old_mouse_y;
static int mouse_grabbed = 0; static int mouse_grabbed = 0;
#define mouse_shouldgrab ((int)vid_glx_fullscreen.value ||(int)_windowed_mouse.value) #define mouse_shouldgrab ((int)vid_glx_fullscreen.value ||(int)_windowed_mouse.value)
#if defined(HAS_DGA) && defined(_EXPERIMENTAL_)) #if defined(HAS_DGA) && defined(_EXPERIMENTAL_)
static int nummodes; static int nummodes;
static XF86VidModeModeInfo **vidmodes; static XF86VidModeModeInfo **vidmodes;
static int hasdga = 0, hasdgavideo = 0, hasvidmode = 0; static int hasdga = 0, hasdgavideo = 0, hasvidmode = 0;
@ -303,7 +303,7 @@ do_grabs(int grab)
XGrabKeyboard(dpy, win, False, GrabModeAsync, GrabModeAsync, XGrabKeyboard(dpy, win, False, GrabModeAsync, GrabModeAsync,
CurrentTime); CurrentTime);
#if defined(HAS_DGA) && defined(_EXPERIMENTAL_)) #if defined(HAS_DGA) && defined(_EXPERIMENTAL_)
if (hasdga) { if (hasdga) {
XF86DGADirectVideo(dpy, screen, XF86DGADirectMouse); XF86DGADirectVideo(dpy, screen, XF86DGADirectMouse);
dgamouse = 1; dgamouse = 1;
@ -318,7 +318,7 @@ do_grabs(int grab)
/* /*
Release grab Release grab
*/ */
#if defined(HAS_DGA) && defined(_EXPERIMENTAL_)) #if defined(HAS_DGA) && defined(_EXPERIMENTAL_)
if (dgamouse) { if (dgamouse) {
XF86DGADirectVideo(dpy, screen, 0); XF86DGADirectVideo(dpy, screen, 0);
dgamouse = 0; dgamouse = 0;
@ -350,7 +350,7 @@ do_fullscreen(int full)
return; return;
} }
#endif #endif
#if defined(HAS_DGA) && defined(_EXPERIMENTAL_)) #if defined(HAS_DGA) && defined(_EXPERIMENTAL_)
if (hasvidmode) { if (hasvidmode) {
static int prev_x = 0, prev_y = 0, prev_w = 640, prev_h = 480; static int prev_x = 0, prev_y = 0, prev_w = 640, prev_h = 480;
@ -422,7 +422,7 @@ GetEvent(void)
break; break;
case MotionNotify: case MotionNotify:
#if defined(HAS_DGA) && defined(_EXPERIMENTAL_)) #if defined(HAS_DGA) && defined(_EXPERIMENTAL_)
if (dgamouse) { if (dgamouse) {
mouse_x += (float)x_event.xmotion.x_root mouse_x += (float)x_event.xmotion.x_root
* vid_dga_mouseaccel.value; * vid_dga_mouseaccel.value;
@ -515,7 +515,7 @@ VID_Shutdown(void)
glXDestroyContext(dpy, ctx); glXDestroyContext(dpy, ctx);
ctx = NULL; ctx = NULL;
#if defined(HAS_DGA) && defined(_EXPERIMENTAL_)) #if defined(HAS_DGA) && defined(_EXPERIMENTAL_)
if (hasvidmode) { if (hasvidmode) {
int i; int i;
@ -769,7 +769,7 @@ void VID_Init(unsigned char *palette)
Cvar_RegisterVariable(&gl_ztrick); Cvar_RegisterVariable(&gl_ztrick);
Cvar_RegisterVariable(&_windowed_mouse); Cvar_RegisterVariable(&_windowed_mouse);
Cvar_RegisterVariable(&vid_glx_fullscreen); Cvar_RegisterVariable(&vid_glx_fullscreen);
#if defined(HAS_DGA) && defined(_EXPERIMENTAL_)) #if defined(HAS_DGA) && defined(_EXPERIMENTAL_)
Cvar_RegisterVariable(&vid_dga_mouseaccel); Cvar_RegisterVariable(&vid_dga_mouseaccel);
#endif #endif
@ -818,7 +818,7 @@ void VID_Init(unsigned char *palette)
exit(1); exit(1);
} }
#if defined(HAS_DGA) && defined(_EXPERIMENTAL_)) #if defined(HAS_DGA) && defined(_EXPERIMENTAL_)
{ {
int maj_ver; int maj_ver;
@ -994,7 +994,7 @@ void VID_ExtraOptionCmd(int option_cursor)
Cvar_SetValue("_windowed_mouse", !_windowed_mouse.value); Cvar_SetValue("_windowed_mouse", !_windowed_mouse.value);
break; break;
#if defined(XMESA) || (defined(HAS_DGA) && defined(_EXPERIMENTAL_)) #if defined(XMESA) || (defined(HAS_DGA) && defined(_EXPERIMENTAL_)
case 2: case 2:
Cvar_SetValue ("vid_glx_fullscreen",!vid_glx_fullscreen.value); Cvar_SetValue ("vid_glx_fullscreen",!vid_glx_fullscreen.value);
break; break;