diff options
author | Sven Gothel <[email protected]> | 2011-11-26 16:46:37 +0100 |
---|---|---|
committer | Sven Gothel <[email protected]> | 2011-11-26 16:46:37 +0100 |
commit | 8cecd0c2963d982aa119cbb07698e56b9c271188 (patch) | |
tree | 65a907b800f7bf8bc14da97ecc7902a9fbb78c14 | |
parent | 0c7f98ddba346668d928b1b7e82a7c7899c72e19 (diff) |
X11Screen RANDR: Use temp display connection due to arbirary failures sometimes
-rw-r--r-- | src/newt/classes/jogamp/newt/driver/x11/X11Screen.java | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/src/newt/classes/jogamp/newt/driver/x11/X11Screen.java b/src/newt/classes/jogamp/newt/driver/x11/X11Screen.java index 0b46e39cb..aec24e316 100644 --- a/src/newt/classes/jogamp/newt/driver/x11/X11Screen.java +++ b/src/newt/classes/jogamp/newt/driver/x11/X11Screen.java @@ -33,7 +33,7 @@ */ package jogamp.newt.driver.x11; -// import jogamp.nativewindow.x11.X11Util; +import jogamp.nativewindow.x11.X11Util; import jogamp.newt.DisplayImpl; import jogamp.newt.ScreenImpl; import jogamp.newt.DisplayImpl.DisplayRunnable; @@ -258,13 +258,12 @@ public class X11Screen extends ScreenImpl { // Internals only // private final <T> T runWithLockedDisplayHandle(DisplayRunnable<T> action) { - return display.runWithLockedDisplayHandle(action); - // return runWithLockedTempDisplayHandle(action); + // return display.runWithLockedDisplayHandle(action); + return runWithTempDisplayHandle(action); // return runWithoutLock(action); } - /** just here to debug X11 RANDR / GL locking issues - private final <T> T runWithLockedTempDisplayHandle(DisplayRunnable<T> action) { + private final <T> T runWithTempDisplayHandle(DisplayRunnable<T> action) { final long displayHandle = X11Util.openDisplay(display.getName()); if(0 == displayHandle) { throw new RuntimeException("null device"); @@ -279,7 +278,7 @@ public class X11Screen extends ScreenImpl { } private final <T> T runWithoutLock(DisplayRunnable<T> action) { return action.run(display.getHandle()); - } */ + } private static native long GetScreen0(long dpy, int scrn_idx); |