Commit fbe8ae99 authored by Camilla Löwy's avatar Camilla Löwy
Browse files

X11: Fix parent window handle initialization

This should have been initialized to the screen root, not None.  This
issue was introduced by fe57e3c2921a1901390534e1e51053df70b5644b.

Fixes #1620.

(cherry picked from commit 9372ba95faabd1bb45280d201d6ccdae77bf872e)
parent 487e0419
...@@ -622,6 +622,7 @@ static GLFWbool createNativeWindow(_GLFWwindow* window, ...@@ -622,6 +622,7 @@ static GLFWbool createNativeWindow(_GLFWwindow* window,
_glfwGrabErrorHandlerX11(); _glfwGrabErrorHandlerX11();
window->x11.parent = _glfw.x11.root;
window->x11.handle = XCreateWindow(_glfw.x11.display, window->x11.handle = XCreateWindow(_glfw.x11.display,
_glfw.x11.root, _glfw.x11.root,
0, 0, // Position 0, 0, // Position
...@@ -1258,12 +1259,6 @@ static void processEvent(XEvent *event) ...@@ -1258,12 +1259,6 @@ static void processEvent(XEvent *event)
switch (event->type) switch (event->type)
{ {
case CreateNotify:
{
window->x11.parent = event->xcreatewindow.parent;
return;
}
case ReparentNotify: case ReparentNotify:
{ {
window->x11.parent = event->xreparent.parent; window->x11.parent = event->xreparent.parent;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment