diff options
author | Sven Gothel <[email protected]> | 2012-02-13 14:27:53 +0100 |
---|---|---|
committer | Sven Gothel <[email protected]> | 2012-02-13 14:27:53 +0100 |
commit | be91765959db646cca0b03537f140da9fecd7450 (patch) | |
tree | 211429df09b040018641b45751d0e721c716d330 /src/test | |
parent | f2bc8fe1f93b5a112093d9507bdb397e3b390215 (diff) |
OSX CALayer fix for Java7 (force CALayer to 0/0, always remove all animations)
Diffstat (limited to 'src/test')
2 files changed, 38 insertions, 9 deletions
diff --git a/src/test/com/jogamp/opengl/test/junit/newt/parenting/TestParentingOffscreenLayer01GLCanvasAWT.java b/src/test/com/jogamp/opengl/test/junit/newt/parenting/TestParentingOffscreenLayer01GLCanvasAWT.java index 1367a27dd..8ec65bf50 100644 --- a/src/test/com/jogamp/opengl/test/junit/newt/parenting/TestParentingOffscreenLayer01GLCanvasAWT.java +++ b/src/test/com/jogamp/opengl/test/junit/newt/parenting/TestParentingOffscreenLayer01GLCanvasAWT.java @@ -47,6 +47,7 @@ import org.junit.Assert; import org.junit.BeforeClass; import org.junit.Test; +import com.jogamp.common.os.Platform; import com.jogamp.newt.Window; import com.jogamp.newt.opengl.GLWindow; import com.jogamp.opengl.test.junit.jogl.demos.es2.GearsES2; @@ -103,10 +104,22 @@ public class TestParentingOffscreenLayer01GLCanvasAWT extends UITestCase { w.destroy(); } } + + @Test + public void testInfo00() throws InterruptedException, InvocationTargetException { + System.err.println("Java Version: "+Platform.getJavaVersionNumber()); + System.err.println("OS Version: "+Platform.getOSVersionNumber()); + System.err.println("JAWTUtil.isOffscreenLayerRequired(): "+JAWTUtil.isOffscreenLayerRequired()); + System.err.println("JAWTUtil.isOffscreenLayerSupported(): "+JAWTUtil.isOffscreenLayerSupported()); + } @Test public void testOnscreenLayerGLCanvas_Onscreen() throws InterruptedException, InvocationTargetException { - testOffscreenLayerGLCanvas_Impl(false, false); + if(!JAWTUtil.isOffscreenLayerRequired()) { + testOffscreenLayerGLCanvas_Impl(false, false); + } else { + System.err.println("onscreen layer n/a"); + } } /** We have no GLCanvas OffscreenWindow as we have for NEWT .. test disabled. @@ -116,8 +129,12 @@ public class TestParentingOffscreenLayer01GLCanvasAWT extends UITestCase { } */ @Test - public void testOffscreenLayerGLCanvas_OffscreenLayerWithOnscreenClass() throws InterruptedException, InvocationTargetException { - testOffscreenLayerGLCanvas_Impl(true, false); + public void testOffscreenLayerGLCanvas_OffscreenLayerWithOnscreenClass() throws InterruptedException, InvocationTargetException { + if(JAWTUtil.isOffscreenLayerSupported()) { + testOffscreenLayerGLCanvas_Impl(true, false); + } else { + System.err.println("offscreen layer n/a"); + } } private void testOffscreenLayerGLCanvas_Impl(boolean offscreenLayer, boolean offscreenClass) throws InterruptedException, InvocationTargetException { diff --git a/src/test/com/jogamp/opengl/test/junit/newt/parenting/TestParentingOffscreenLayer02NewtCanvasAWT.java b/src/test/com/jogamp/opengl/test/junit/newt/parenting/TestParentingOffscreenLayer02NewtCanvasAWT.java index bc59c7378..6a1980b90 100644 --- a/src/test/com/jogamp/opengl/test/junit/newt/parenting/TestParentingOffscreenLayer02NewtCanvasAWT.java +++ b/src/test/com/jogamp/opengl/test/junit/newt/parenting/TestParentingOffscreenLayer02NewtCanvasAWT.java @@ -106,17 +106,29 @@ public class TestParentingOffscreenLayer02NewtCanvasAWT extends UITestCase { @Test public void testOnscreenLayerNewtCanvas_Onscreen() throws InterruptedException, InvocationTargetException { - testOffscreenLayerNewtCanvas_Impl(false, false); + if(!JAWTUtil.isOffscreenLayerRequired()) { + testOffscreenLayerNewtCanvas_Impl(false, false); + } else { + System.err.println("onscreen layer n/a"); + } } - @Test - public void testOffscreenLayerNewtCanvas_OffscreenLayerWithOffscreenClass() throws InterruptedException, InvocationTargetException { - testOffscreenLayerNewtCanvas_Impl(true, true); + // @Test + public void testOffscreenLayerNewtCanvas_OffscreenLayerWithOffscreenClass() throws InterruptedException, InvocationTargetException { + if(JAWTUtil.isOffscreenLayerSupported()) { + testOffscreenLayerNewtCanvas_Impl(true, true); + } else { + System.err.println("offscreen layer n/a"); + } } @Test - public void testOffscreenLayerNewtCanvas_OffscreenLayerWithOnscreenClass() throws InterruptedException, InvocationTargetException { - testOffscreenLayerNewtCanvas_Impl(true, false); + public void testOffscreenLayerNewtCanvas_OffscreenLayerWithOnscreenClass() throws InterruptedException, InvocationTargetException { + if(JAWTUtil.isOffscreenLayerSupported()) { + testOffscreenLayerNewtCanvas_Impl(true, false); + } else { + System.err.println("offscreen layer n/a"); + } } private void testOffscreenLayerNewtCanvas_Impl(boolean offscreenLayer, boolean offscreenClass) throws InterruptedException, InvocationTargetException { |