void VID_Shutdown(void) { if (context == NULL && window == NULL) return; VID_EnableJoystick(false); VID_SetMouse(false, false, false); VID_RestoreSystemGamma(); if (context != NULL) { qaglDestroyContext(context); context = NULL; } if (vid_isfullscreen) CGReleaseAllDisplays(); if (window != NULL) { DisposeWindow(window); window = NULL; } vid_hidden = true; vid_isfullscreen = false; GL_CloseLibrary(); Key_ClearStates (); }
void IN_Move (void) { vid_joystate_t joystate; VID_EnableJoystick(true); VID_BuildJoyState(&joystate); VID_ApplyJoyState(&joystate); }
void VID_Shutdown(void) { if (!vidx11_display) return; VID_EnableJoystick(false); VID_SetMouse(false, false, false); VID_RestoreSystemGamma(); // FIXME: glXDestroyContext here? if (vid_isvidmodefullscreen) XF86VidModeSwitchToMode(vidx11_display, vidx11_screen, &init_vidmode); if(vidx11_gc) XFreeGC(vidx11_display, vidx11_gc); vidx11_gc = NULL; DestroyXImages(); vidx11_shmevent = -1; vid.softpixels = NULL; if (vid.softdepthpixels) free(vid.softdepthpixels); vid.softdepthpixels = NULL; if (win) XDestroyWindow(vidx11_display, win); XCloseDisplay(vidx11_display); vid_hidden = true; vid_isfullscreen = false; vid_isnetwmfullscreen = false; vid_isvidmodefullscreen = false; vid_isoverrideredirect = false; vidx11_display = NULL; win = 0; ctx = NULL; GL_CloseLibrary(); Key_ClearStates (); }