Glitch64: Do not re-init opengl

This commit is contained in:
zilmar 2013-04-11 12:07:42 +10:00
parent d5dd94a4d7
commit 8746daa1e4
1 changed files with 9 additions and 4 deletions
Source/Glitch64

View File

@ -862,11 +862,16 @@ grSstWinOpen(
return FXFALSE;
}
if (!wglMakeCurrent(hDC, hGLRC))
HGLRC CurrenthGLRC = wglGetCurrentContext();
if (CurrenthGLRC == NULL || CurrenthGLRC == hGLRC)
{
display_warning("wglMakeCurrent failed!");
grSstWinClose(0);
return FXFALSE;
if (!wglMakeCurrent(hDC, hGLRC))
{
display_warning("wglMakeCurrent failed!");
grSstWinClose(0);
return FXFALSE;
}
}
#else // _WIN32