diff options
-rw-r--r-- | make/scripts/test-demo-launcher0.sh | 2 | ||||
-rw-r--r-- | src/newt/classes/jogamp/newt/DisplayImpl.java | 8 |
2 files changed, 9 insertions, 1 deletions
diff --git a/make/scripts/test-demo-launcher0.sh b/make/scripts/test-demo-launcher0.sh index 330c71230..4004726a7 100644 --- a/make/scripts/test-demo-launcher0.sh +++ b/make/scripts/test-demo-launcher0.sh @@ -49,6 +49,8 @@ X_ARGS="-Djava.awt.headless=true $X_ARGS" #D_ARGS="-Djogl.debug=all" #D_ARGS="-Djogl.debug=all -Dnewt.debug=all -Djogl.debug.DebugGL" #D_ARGS="-Dnewt.debug=all" +D_ARGS="-Dnewt.debug.Display.PointerIcon -Dnewt.disable.PointerIcon" + #D_ARGS="-Dnewt.disable.LinuxKeyEventTracker -Dnewt.disable.LinuxMouseTracker" #D_ARGS="-Dnewt.disable.LinuxKeyEventTracker" #D_ARGS="-Dnativewindow.debug=all -Djogl.debug=all -Dnewt.debug=all -Dnewt.disable.LinuxKeyEventTracker -Dnewt.disable.LinuxMouseTracker" diff --git a/src/newt/classes/jogamp/newt/DisplayImpl.java b/src/newt/classes/jogamp/newt/DisplayImpl.java index 62550ee0c..7fdcb4d7d 100644 --- a/src/newt/classes/jogamp/newt/DisplayImpl.java +++ b/src/newt/classes/jogamp/newt/DisplayImpl.java @@ -38,6 +38,7 @@ import com.jogamp.common.ExceptionUtils; import com.jogamp.common.nio.Buffers; import com.jogamp.common.util.IOUtil; import com.jogamp.common.util.InterruptedRuntimeException; +import com.jogamp.common.util.PropertyAccess; import com.jogamp.common.util.ReflectionUtil; import com.jogamp.newt.Display; import com.jogamp.newt.NewtFactory; @@ -64,6 +65,7 @@ import com.jogamp.nativewindow.util.Point; import com.jogamp.nativewindow.util.PointImmutable; public abstract class DisplayImpl extends Display { + protected static final boolean DISABLE_POINTER_ICON = PropertyAccess.isPropertyDefined("newt.disable.PointerIcon", true); private static int serialno = 1; private static final boolean pngUtilAvail; @@ -240,7 +242,11 @@ public abstract class DisplayImpl extends Display { if( getNativePointerIconForceDirectNIO() && !Buffers.isDirect(pixels) ) { throw new IllegalArgumentException("pixel buffer is not direct "+pixels); } - return createPointerIconImpl(pixelformat, width, height, pixels, hotX, hotY); + if( !DISABLE_POINTER_ICON ) { + return createPointerIconImpl(pixelformat, width, height, pixels, hotX, hotY); + } else { + return 0; + } } /** |