From 30b2829fb1b1832b055ffdb4d60b0ad0878a9ac0 Mon Sep 17 00:00:00 2001 From: kervala Date: Thu, 30 Dec 2010 22:18:23 +0100 Subject: [PATCH] Changed: Don't modify NeL window if managed by a 3rd party library --- code/nel/src/3d/driver/opengl/driver_opengl_window.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/code/nel/src/3d/driver/opengl/driver_opengl_window.cpp b/code/nel/src/3d/driver/opengl/driver_opengl_window.cpp index ead9020b4..82855c80d 100644 --- a/code/nel/src/3d/driver/opengl/driver_opengl_window.cpp +++ b/code/nel/src/3d/driver/opengl/driver_opengl_window.cpp @@ -1786,7 +1786,11 @@ bool CDriverGL::setWindowStyle(EWindowStyle windowStyle) // -------------------------------------------------- bool CDriverGL::setMode(const GfxMode& mode) { - H_AUTO_OGL(CDriverGL_setMode) + H_AUTO_OGL(CDriverGL_setMode); + + // don't modify window or screen if managed by a 3rd party library + if (!_DestroyWindow) + return false; if (!setScreenMode(mode)) return false;