Merge pull request #6647 from deathbeam/properly-close-gl-context
Properly close GL context and lock surface
This commit is contained in:
@@ -376,17 +376,20 @@ public class GpuPlugin extends Plugin implements DrawCallbacks
|
||||
shutdownProgram();
|
||||
shutdownVao();
|
||||
shutdownStretchedFbo();
|
||||
}
|
||||
|
||||
if (jawtWindow != null)
|
||||
{
|
||||
if (!jawtWindow.getLock().isLocked())
|
||||
{
|
||||
jawtWindow.lockSurface();
|
||||
}
|
||||
|
||||
glContext.destroy();
|
||||
}
|
||||
if (glContext != null)
|
||||
{
|
||||
glContext.destroy();
|
||||
}
|
||||
|
||||
if (jawtWindow != null)
|
||||
{
|
||||
NewtFactoryAWT.destroyNativeWindow(jawtWindow);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user