diff options
Diffstat (limited to 'src/junit/com/jogamp')
3 files changed, 6 insertions, 22 deletions
diff --git a/src/junit/com/jogamp/test/junit/jogl/demos/gl2/gears/TestGearsNewtAWTWrapper.java b/src/junit/com/jogamp/test/junit/jogl/demos/gl2/gears/TestGearsNewtAWTWrapper.java index fb25ae399..51977d6d3 100755 --- a/src/junit/com/jogamp/test/junit/jogl/demos/gl2/gears/TestGearsNewtAWTWrapper.java +++ b/src/junit/com/jogamp/test/junit/jogl/demos/gl2/gears/TestGearsNewtAWTWrapper.java @@ -67,7 +67,7 @@ public class TestGearsNewtAWTWrapper { protected void runTestGL(GLCapabilities caps) throws InterruptedException { Display nDisplay = NewtFactory.createDisplay(NativeWindowFactory.TYPE_AWT, null); // local display Screen nScreen = NewtFactory.createScreen(NativeWindowFactory.TYPE_AWT, nDisplay, 0); // screen 0 - Window nWindow = NewtFactory.createWindow(NativeWindowFactory.TYPE_AWT, nScreen, caps); + Window nWindow = NewtFactory.createWindow(NativeWindowFactory.TYPE_AWT, nScreen, caps, false); GLWindow glWindow = GLWindow.create(nWindow); Assert.assertNotNull(glWindow); diff --git a/src/junit/com/jogamp/test/junit/newt/TestParenting01AWT.java b/src/junit/com/jogamp/test/junit/newt/TestParenting01AWT.java index c46ec3941..9d0001733 100755 --- a/src/junit/com/jogamp/test/junit/newt/TestParenting01AWT.java +++ b/src/junit/com/jogamp/test/junit/newt/TestParenting01AWT.java @@ -131,7 +131,7 @@ public class TestParenting01AWT { NEWTEventFiFo eventFifo = new NEWTEventFiFo(); - Window window2 = NewtFactory.createWindow(overlayedAWTComponent, screen, caps); + Window window2 = NewtFactory.createWindow(overlayedAWTComponent, screen, caps, false); Assert.assertNotNull(window2); GLWindow glWindow2 = GLWindow.create(window2); @@ -145,14 +145,12 @@ public class TestParenting01AWT { glWindow2.setTitle("NEWT - CHILD"); glWindow2.addKeyListener(new TraceKeyAdapter(new KeyAction(eventFifo))); glWindow2.addWindowListener(new TraceWindowAdapter(new WindowAction(eventFifo))); + glWindow2.setVisible(true); GLEventListener demo2 = new Gears(); setDemoFields(demo2, window2, glWindow2, false); glWindow2.addGLEventListener(demo2); - glWindow2.setVisible(true); - glWindow2.display(); - long duration = durationPerTest; long step = 20; NEWTEvent event; diff --git a/src/junit/com/jogamp/test/junit/newt/TestParenting01NEWT.java b/src/junit/com/jogamp/test/junit/newt/TestParenting01NEWT.java index cd85d1c9a..1940534dd 100755 --- a/src/junit/com/jogamp/test/junit/newt/TestParenting01NEWT.java +++ b/src/junit/com/jogamp/test/junit/newt/TestParenting01NEWT.java @@ -70,21 +70,14 @@ public class TestParenting01NEWT { static Window createWindow(NativeWindow parent, Screen screen, Capabilities caps, int width, int height) { Assert.assertNotNull(caps); - // - // Create native windowing resources .. X11/Win/OSX - // Window window; - window = ( null == parent ) ? NewtFactory.createWindow(screen, caps) : NewtFactory.createWindow(parent, screen, caps) ; + window = ( null == parent ) ? NewtFactory.createWindow(screen, caps, false) : NewtFactory.createWindow(parent, screen, caps, false) ; Assert.assertNotNull(window); window.setSize(width, height); Assert.assertTrue(false==window.isVisible()); Assert.assertTrue(width==window.getWidth()); Assert.assertTrue(height==window.getHeight()); - // - // Create native OpenGL resources .. XGL/WGL/CGL .. - // equivalent to GLAutoDrawable methods: setVisible(true) - // caps = window.getGraphicsConfiguration().getNativeGraphicsConfiguration().getChosenCapabilities(); Assert.assertNotNull(caps); Assert.assertTrue(caps.getGreenBits()>5); @@ -134,6 +127,7 @@ public class TestParenting01NEWT { glWindow1.setPosition(x,y); glWindow1.addKeyListener(new TraceKeyAdapter(new KeyAction(eventFifo))); glWindow1.addWindowListener(new TraceWindowAdapter()); + glWindow1.setVisible(true); Window window2 = createWindow(window1, screen, caps, width/2, height/2); Assert.assertNotNull(window2); @@ -146,6 +140,7 @@ public class TestParenting01NEWT { glWindow2.addKeyListener(new TraceKeyAdapter(new KeyAction(eventFifo))); glWindow2.addWindowListener(new TraceWindowAdapter(new WindowAction(eventFifo))); // glWindow2.addMouseListener(new TraceMouseAdapter()); + glWindow2.setVisible(true); GLEventListener demo1 = new RedSquare(); setDemoFields(demo1, window1, glWindow1, false); @@ -155,15 +150,6 @@ public class TestParenting01NEWT { setDemoFields(demo2, window2, glWindow2, false); glWindow2.addGLEventListener(demo2); - glWindow2.setVisible(true); - glWindow1.setVisible(true); - - glWindow2.setVisible(true); - glWindow1.setVisible(true); - - glWindow2.display(); - glWindow1.display(); - boolean shouldQuit = false; long duration = durationPerTest; long step = 20; |