|
From: <ka...@us...> - 2011-10-26 20:24:29
|
Revision: 3688
http://java-game-lib.svn.sourceforge.net/java-game-lib/?rev=3688&view=rev
Author: kappa1
Date: 2011-10-26 20:24:22 +0000 (Wed, 26 Oct 2011)
Log Message:
-----------
Only set X window hints on the Linux native display window when not using Display.setParent()
Modified Paths:
--------------
trunk/LWJGL/src/native/linux/opengl/org_lwjgl_opengl_Display.c
trunk/LWJGL/src/native/linux/opengles/org_lwjgl_opengl_Display.c
Modified: trunk/LWJGL/src/native/linux/opengl/org_lwjgl_opengl_Display.c
===================================================================
--- trunk/LWJGL/src/native/linux/opengl/org_lwjgl_opengl_Display.c 2011-10-25 17:42:56 UTC (rev 3687)
+++ trunk/LWJGL/src/native/linux/opengl/org_lwjgl_opengl_Display.c 2011-10-26 20:24:22 UTC (rev 3688)
@@ -376,8 +376,10 @@
setDecorations(disp, win, 0);
}
- updateWindowBounds(disp, win, x, y, width, height, JNI_TRUE, resizable);
- updateWindowHints(env, disp, win);
+ if (RootWindow(disp, screen) == parent_handle) { // on set hints when Display.setParent isn't used
+ updateWindowBounds(disp, win, x, y, width, height, JNI_TRUE, resizable);
+ updateWindowHints(env, disp, win);
+ }
#define NUM_ATOMS 1
Atom protocol_atoms[NUM_ATOMS] = {XInternAtom(disp, "WM_DELETE_WINDOW", False)/*, XInternAtom(disp, "WM_TAKE_FOCUS", False)*/};
Modified: trunk/LWJGL/src/native/linux/opengles/org_lwjgl_opengl_Display.c
===================================================================
--- trunk/LWJGL/src/native/linux/opengles/org_lwjgl_opengl_Display.c 2011-10-25 17:42:56 UTC (rev 3687)
+++ trunk/LWJGL/src/native/linux/opengles/org_lwjgl_opengl_Display.c 2011-10-26 20:24:22 UTC (rev 3688)
@@ -370,8 +370,10 @@
setDecorations(disp, win, 0);
}
- updateWindowBounds(disp, win, x, y, width, height, JNI_TRUE, resizable);
- updateWindowHints(env, disp, win);
+ if (RootWindow(disp, screen) == parent_handle) { // on set hints when Display.setParent isn't used
+ updateWindowBounds(disp, win, x, y, width, height, JNI_TRUE, resizable);
+ updateWindowHints(env, disp, win);
+ }
#define NUM_ATOMS 1
Atom protocol_atoms[NUM_ATOMS] = {XInternAtom(disp, "WM_DELETE_WINDOW", False)/*, XInternAtom(disp, "WM_TAKE_FOCUS", False)*/};
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|