Fix handling of GDK_NONE

Don't intern "NONE" and warn if GDK_NONE is converted to an
X atom. Problem pointed out in bug 580511.
This commit is contained in:
Matthias Clasen
2009-05-03 21:38:54 -04:00
parent e4bbfd9a4b
commit 6aa6338578
2 changed files with 13 additions and 8 deletions

View File

@ -404,7 +404,10 @@ gdk_selection_send_notify_for_display (GdkDisplay *display,
xevent.requestor = requestor;
xevent.selection = gdk_x11_atom_to_xatom_for_display (display, selection);
xevent.target = gdk_x11_atom_to_xatom_for_display (display, target);
xevent.property = gdk_x11_atom_to_xatom_for_display (display, property);
if (property == GDK_NONE)
xevent.property = None;
else
xevent.property = gdk_x11_atom_to_xatom_for_display (display, property);
xevent.time = time;
_gdk_send_xevent (display, requestor, False, NoEventMask, (XEvent*) & xevent);