if (hRC)
wglDeleteContext(hRC);
+ // close the library before we get rid of the window
+ GL_CloseLibrary();
+
if (hDC && mainwindow)
ReleaseDC(mainwindow, hDC);
VID_RestoreSystemGamma();
}
-
- GL_CloseLibrary();
}
static BOOL sound_active;
vid_activewindow = fActive;
- Minimized = minimize;
+ vid_hidden = minimize;
// enable/disable sound on focus gain/loss
if (!vid_activewindow && sound_active)