Comprehensively zero all unused parts of client messages (Mainly Motif DND

Tue May 20 15:09:29 2003  Owen Taylor  <otaylor@redhat.com>

        * gdk/x11/gdkdnd-x11.c gdk/x11/gdkwindow-x11.c: Comprehensively
        zero all unused parts of client messages (Mainly Motif DND
        and EWMH). Also, fix a couple places where we were putting
        contents into Motif DND messages that didn't belong.
        (#113361, EWMH problem reported by Lubos Lunak)

        * gtk/gtkselection.c (_gtk_selection_request): Handle the
        case where the property type for the multiple atoms is
        ATOM_PAIR by doing the conversions ourselve. This is
        needed for Xt inter-operation.
This commit is contained in:
Owen Taylor
2003-05-20 21:01:08 +00:00
committed by Owen Taylor
parent 27a0a3bf22
commit ef6053684b
9 changed files with 169 additions and 29 deletions

View File

@ -899,6 +899,9 @@ _gdk_windowing_window_destroy (GdkWindow *window,
xevent.data.l[0] = gdk_x11_get_xatom_by_name_for_display (GDK_WINDOW_DISPLAY (window),
"WM_DELETE_WINDOW");
xevent.data.l[1] = CurrentTime;
xevent.data.l[2] = 0;
xevent.data.l[3] = 0;
xevent.data.l[4] = 0;
XSendEvent (GDK_WINDOW_XDISPLAY (window),
GDK_WINDOW_XID (window),
@ -1565,6 +1568,10 @@ gdk_window_focus (GdkWindow *window,
"_NET_ACTIVE_WINDOW");
xev.xclient.format = 32;
xev.xclient.data.l[0] = 0;
xev.xclient.data.l[1] = 0;
xev.xclient.data.l[2] = 0;
xev.xclient.data.l[3] = 0;
xev.xclient.data.l[4] = 0;
XSendEvent (GDK_WINDOW_XDISPLAY (window), GDK_WINDOW_XROOTWIN (window), False,
SubstructureRedirectMask | SubstructureNotifyMask,
@ -1742,6 +1749,8 @@ gdk_wmspec_change_state (gboolean add,
xev.xclient.data.l[0] = add ? _NET_WM_STATE_ADD : _NET_WM_STATE_REMOVE;
xev.xclient.data.l[1] = gdk_x11_atom_to_xatom_for_display (display, state1);
xev.xclient.data.l[2] = gdk_x11_atom_to_xatom_for_display (display, state2);
xev.xclient.data.l[3] = 0;
xev.xclient.data.l[4] = 0;
XSendEvent (GDK_WINDOW_XDISPLAY (window), GDK_WINDOW_XROOTWIN (window), False,
SubstructureRedirectMask | SubstructureNotifyMask,
@ -3473,6 +3482,10 @@ gdk_window_stick (GdkWindow *window)
xev.xclient.format = 32;
xev.xclient.data.l[0] = 0xFFFFFFFF;
xev.xclient.data.l[1] = 0;
xev.xclient.data.l[2] = 0;
xev.xclient.data.l[3] = 0;
xev.xclient.data.l[4] = 0;
XSendEvent (GDK_WINDOW_XDISPLAY (window), GDK_WINDOW_XROOTWIN (window), False,
SubstructureRedirectMask | SubstructureNotifyMask,
@ -3537,6 +3550,10 @@ gdk_window_unstick (GdkWindow *window)
xev.xclient.format = 32;
xev.xclient.data.l[0] = *current_desktop;
xev.xclient.data.l[1] = 0;
xev.xclient.data.l[2] = 0;
xev.xclient.data.l[3] = 0;
xev.xclient.data.l[4] = 0;
XSendEvent (GDK_DISPLAY_XDISPLAY (display), GDK_WINDOW_XROOTWIN (window), False,
SubstructureRedirectMask | SubstructureNotifyMask,