diff options
-rwxr-xr-x | make/scripts/java-run-all.sh | 4 | ||||
-rw-r--r-- | src/newt/classes/com/jogamp/newt/Display.java | 1 | ||||
-rw-r--r-- | src/newt/classes/com/jogamp/newt/util/MainThread.java | 6 |
3 files changed, 7 insertions, 4 deletions
diff --git a/make/scripts/java-run-all.sh b/make/scripts/java-run-all.sh index f99a49617..16353dff2 100755 --- a/make/scripts/java-run-all.sh +++ b/make/scripts/java-run-all.sh @@ -44,8 +44,10 @@ uname -a | grep -i Darwin && MOSX=1 # D_ARGS="-Dnewt.debug=all -Dnativewindow.debug=all" # D_ARGS="-Djogl.debug=all -Dnewt.debug=all -Dnativewindow.debug=all" # D_ARGS="-Dnewt.debug=all" -D_ARGS="-Dnewt.debug.Window" +# D_ARGS="-Dnewt.debug.Window" # D_ARGS="-Dnewt.debug.Display" +# D_ARGS="-Dnewt.debug.Window -Dnewt.debug.TestEDTMainThread" +# D_ARGS="-Dnewt.debug.TestEDTMainThread" # D_ARGS="-Djogl.debug=all -Djogl.debug.DynamicLookup=true -Djogamp.debug.NativeLibrary=true" # D_ARGS="-Djogl.debug=all" # D_ARGS="-Djogamp.debug.JNILibLoader=true -Djogamp.debug.NativeLibrary=true -Djogamp.debug.NativeLibrary.Lookup=true -Djogl.debug.GLProfile=true" diff --git a/src/newt/classes/com/jogamp/newt/Display.java b/src/newt/classes/com/jogamp/newt/Display.java index 91fff890c..a8ab8d520 100644 --- a/src/newt/classes/com/jogamp/newt/Display.java +++ b/src/newt/classes/com/jogamp/newt/Display.java @@ -209,6 +209,7 @@ public abstract class Display { f_dpy.dispatchMessages(); } } } ); edtUtil = MainThread.getSingleton(); + System.err.println("Display.getEDTUtil("+getFQName()+") Test EDT MainThread: "+edtUtil.getClass().getName()); // End JAU EDT Test .. } edtUtil.start(); diff --git a/src/newt/classes/com/jogamp/newt/util/MainThread.java b/src/newt/classes/com/jogamp/newt/util/MainThread.java index ed78c808d..ba886ade8 100644 --- a/src/newt/classes/com/jogamp/newt/util/MainThread.java +++ b/src/newt/classes/com/jogamp/newt/util/MainThread.java @@ -46,7 +46,6 @@ import javax.media.nativewindow.*; import com.jogamp.common.util.*; import com.jogamp.newt.*; import com.jogamp.newt.impl.*; -import com.jogamp.newt.impl.macosx.MacDisplay; /** * NEWT Utility class MainThread<P> @@ -178,7 +177,8 @@ public class MainThread implements EDTUtil { mainAction = new MainAction(mainClassName, mainClassArgs); if(NativeWindowFactory.TYPE_MACOSX.equals(NativeWindowFactory.getNativeWindowType(false))) { - MacDisplay.initSingleton(); + ReflectionUtil.callStaticMethod("com.jogamp.newt.impl.macosx.MacDisplay", "initSingleton", + null, null, MainThread.class.getClassLoader()); } if ( useMainThread ) { @@ -235,7 +235,7 @@ public class MainThread implements EDTUtil { private void initAWTReflection() { if(null == cAWTEventQueue) { - ClassLoader cl = MacDisplay.class.getClassLoader(); + ClassLoader cl = MainThread.class.getClassLoader(); cAWTEventQueue = ReflectionUtil.getClass("java.awt.EventQueue", true, cl); mAWTInvokeAndWait = ReflectionUtil.getMethod(cAWTEventQueue, "invokeAndWait", new Class[] { java.lang.Runnable.class }, cl); mAWTInvokeLater = ReflectionUtil.getMethod(cAWTEventQueue, "invokeLater", new Class[] { java.lang.Runnable.class }, cl); |