vcl/source/opengl/OpenGLContext.cxx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
New commits: commit 3c046ac76fd87e2ed49561b3e6240f3778644279 Author: Jan Holesovsky <ke...@collabora.com> Date: Wed Sep 2 11:37:17 2015 +0200 windows opengl: Avoid an unnecessary wglMakeCurrent() call. Change-Id: I1c1287a29067c053565c49c0ce96918a2d27d87f diff --git a/vcl/source/opengl/OpenGLContext.cxx b/vcl/source/opengl/OpenGLContext.cxx index f6cd458..f3eeb7c 100644 --- a/vcl/source/opengl/OpenGLContext.cxx +++ b/vcl/source/opengl/OpenGLContext.cxx @@ -1190,7 +1190,6 @@ void OpenGLContext::reset() // destroy all programs if( !maPrograms.empty() ) { - makeCurrent(); maPrograms.clear(); } @@ -1208,7 +1207,8 @@ void OpenGLContext::reset() if (itr != g_vShareList.end()) g_vShareList.erase(itr); - wglMakeCurrent(NULL, NULL); + if (wglGetCurrentContext() != NULL) + wglMakeCurrent(NULL, NULL); wglDeleteContext( m_aGLWin.hRC ); ReleaseDC( m_aGLWin.hWnd, m_aGLWin.hDC ); } _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits