spawn_window.c
static void sendXdndLeave(Display *disp, Window source, Window target)
{
	if (xdndState.xdndExchangeStarted && xdndState.amISource) {
		// Declare message struct and populate its values
		XEvent message;
		memset(&message, 0, sizeof(message));
		message.xclient.type = ClientMessage;
		message.xclient.display = disp;
		message.xclient.window = target;
		message.xclient.message_type = XdndLeave;
		message.xclient.format = 32;
		message.xclient.data.l[0] = source;
		// Rest of array members reserved so not set

		// Send it to target window
		if (XSendEvent(disp, target, False, 0, &message) == 0)
			philError("XSendEvent");
	}
}
// This is sent by the source when the exchange is abandoned
This is sent by the source when the exchange is abandoned
This is sent by the source when the exchange is abandoned
static void sendXdndLeave(Display *disp, Window source, Window target)
{
	if (xdndState.xdndExchangeStarted && xdndState.amISource) {
		XEvent message;
		memset(&message, 0, sizeof(message));
		message.xclient.type = ClientMessage;
		message.xclient.display = disp;
		message.xclient.window = target;
		message.xclient.message_type = XdndLeave;
		message.xclient.format = 32;
		message.xclient.data.l[0] = source;
		if (XSendEvent(disp, target, False, 0, &message) == 0)
			philError("XSendEvent");
	}
}
static void sendXdndLeave ( Display * disp , Window source , Window target ) { if ( xdndState . xdndExchangeStarted && xdndState . amISource ) { XEvent message ; memset ( & message , 0 , sizeof ( message ) ) ; message . xclient . type = ClientMessage ; message . xclient . display = disp ; message . xclient . window = target ; message . xclient . message_type = XdndLeave ; message . xclient . format = 32 ; message . xclient . data . l [ 0 ] = source ; if ( XSendEvent ( disp , target , False , 0 , & message ) == 0 ) philError ( " " ) ; } }
This is sent by the source when the exchange is abandoned
This is sent by the source when the exchange is abandoned
// Declare message struct and populate its values // Rest of array members reserved so not set // Send it to target window