From 2915bece47608feaf493a0d463d1639803e493ab Mon Sep 17 00:00:00 2001 From: Grim Maple Date: Sat, 22 Oct 2022 14:35:37 +0300 Subject: [PATCH] Fix some OpenGL context problems --- src/dlangui/platforms/windows/winapp.d | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/dlangui/platforms/windows/winapp.d b/src/dlangui/platforms/windows/winapp.d index d3579c4f..ef6dcf95 100644 --- a/src/dlangui/platforms/windows/winapp.d +++ b/src/dlangui/platforms/windows/winapp.d @@ -477,12 +477,12 @@ class Win32Window : Window { hDC = GetDC(_hwnd); useOpengl = sharedGLContext.reinit(hDC, platform.multisamples); - } - if(!sharedGLContext.createCoreRC(hDC)) - { - Log.d("Unable to create Core OpenGL"); - throw new Exception("Unable to create Core OpenGL"); + if(!sharedGLContext.createCoreRC(hDC)) + { + Log.d("Unable to create Core OpenGL"); + throw new Exception("Unable to create Core OpenGL"); + } } } }