From 835cea627f80d8f8a851514734f53e6336d9d6d9 Mon Sep 17 00:00:00 2001 From: Sven Gothel Date: Mon, 24 Jun 2013 09:48:56 +0200 Subject: TestSWTAccessor03AWTGLn: Fix SWT deadlock on Java7/Windows: Must perform AWT frame close on current thread .. --- .../opengl/test/junit/jogl/swt/TestSWTAccessor03AWTGLn.java | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'src/test/com/jogamp/opengl') diff --git a/src/test/com/jogamp/opengl/test/junit/jogl/swt/TestSWTAccessor03AWTGLn.java b/src/test/com/jogamp/opengl/test/junit/jogl/swt/TestSWTAccessor03AWTGLn.java index 5803a1675..ee5dc7fea 100644 --- a/src/test/com/jogamp/opengl/test/junit/jogl/swt/TestSWTAccessor03AWTGLn.java +++ b/src/test/com/jogamp/opengl/test/junit/jogl/swt/TestSWTAccessor03AWTGLn.java @@ -120,14 +120,18 @@ public class TestSWTAccessor03AWTGLn extends UITestCase { Assert.assertNotNull( shell ); Assert.assertNotNull( composite ); Assert.assertNotNull( glcanvas ); - javax.swing.SwingUtilities.invokeAndWait(new Runnable() { + final Runnable releaseAWT = new Runnable() { public void run() { + // deadlocks Java7 on Windows frame.setVisible(false); frame.remove(glcanvas); frame.dispose(); frame = null; glcanvas = null; - }}); + } }; + // Deadlocks Java7 on Windows + // javax.swing.SwingUtilities.invokeAndWait( releaseAWT ); + releaseAWT.run(); SWTAccessor.invoke(true, new Runnable() { public void run() { -- cgit v1.2.3