src/video/x11/SDL_x11window.c
changeset 6638 3d221da309d3
parent 6575 833a983f218e
child 6662 698c2e533a7e
     1.1 --- a/src/video/x11/SDL_x11window.c	Fri Nov 02 14:15:21 2012 -0400
     1.2 +++ b/src/video/x11/SDL_x11window.c	Fri Nov 02 15:22:37 2012 -0400
     1.3 @@ -536,8 +536,14 @@
     1.4                      PropModeReplace,
     1.5                      (unsigned char *)&_NET_WM_WINDOW_TYPE_NORMAL, 1);
     1.6  
     1.7 -    /* Allow the window to be deleted by the window manager */
     1.8 -    XSetWMProtocols(display, w, &data->WM_DELETE_WINDOW, 1);
     1.9 +    
    1.10 +    {
    1.11 +        Atom protocols[] = {
    1.12 +            data->WM_DELETE_WINDOW, /* Allow window to be deleted by the WM */
    1.13 +            data->_NET_WM_PING, /* Respond so WM knows we're alive */
    1.14 +        };
    1.15 +        XSetWMProtocols(display, w, protocols, sizeof (protocols) / sizeof (protocols[0]));
    1.16 +    }
    1.17  
    1.18      if (SetupWindowData(_this, window, w, SDL_TRUE) < 0) {
    1.19          XDestroyWindow(display, w);