From 3cc7335e94df9daaab5250487b9f03e19aaa292a Mon Sep 17 00:00:00 2001 From: Sven Gothel Date: Sat, 12 Sep 2009 12:32:44 -0700 Subject: NEWT: Basic/Naive window parenting support ; NEWT GLWindow: remove ambigous create functions, ie with Window and Capabilities arguments --- src/newt/native/X11Window.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'src/newt/native/X11Window.c') diff --git a/src/newt/native/X11Window.c b/src/newt/native/X11Window.c index 8651a8cea..1e7cd3bba 100755 --- a/src/newt/native/X11Window.c +++ b/src/newt/native/X11Window.c @@ -511,17 +511,17 @@ JNIEXPORT jboolean JNICALL Java_com_sun_javafx_newt_x11_X11Window_initIDs /* * Class: com_sun_javafx_newt_x11_X11Window * Method: CreateWindow - * Signature: (JIJIIII)J + * Signature: (JJIJIIII)J */ JNIEXPORT jlong JNICALL Java_com_sun_javafx_newt_x11_X11Window_CreateWindow - (JNIEnv *env, jobject obj, jlong display, jint screen_index, + (JNIEnv *env, jobject obj, jlong parent, jlong display, jint screen_index, jlong visualID, jlong javaObjectAtom, jlong windowDeleteAtom, jint x, jint y, jint width, jint height) { Display * dpy = (Display *)(intptr_t)display; int scrn_idx = (int)screen_index; - Window windowParent = 0; + Window windowParent = (Window) parent; Window window = 0; XVisualInfo visualTemplate; @@ -578,7 +578,9 @@ JNIEXPORT jlong JNICALL Java_com_sun_javafx_newt_x11_X11Window_CreateWindow pVisualQuery=NULL; } - windowParent = XRootWindowOfScreen(scrn); + if(NULL==windowParent) { + windowParent = XRootWindowOfScreen(scrn); + } attrMask = (CWBackPixel | CWBorderPixel | CWColormap | CWEventMask | CWOverrideRedirect) ; -- cgit v1.2.3