Initial client-side-windows work

The history before this was kind of twisted as several different
approaches were tested, so that was all squashed into this initial
commit to hide the uninteresting changes and files that were later
removed.
This commit is contained in:
Alexander Larsson
2008-07-18 15:03:42 +02:00
committed by Alexander Larsson
parent e2a2ba9d98
commit eabac453e6
33 changed files with 5638 additions and 1997 deletions

View File

@ -120,6 +120,63 @@ _gdk_event_queue_append (GdkDisplay *display,
return display->queued_tail;
}
/**
* _gdk_event_queue_insert_after:
* @display: a #GdkDisplay
* @sibling: Append after this event.
* @event: Event to append.
*
* Appends an event after the specified event, or if it isn't in
* the queue, onto the tail of the event queue.
*
* Returns: the newly appended list node.
*
* Since: 2.16
*/
GList*
_gdk_event_queue_insert_after (GdkDisplay *display,
GdkEvent *sibling,
GdkEvent *event)
{
GList *prev = g_list_find (display->queued_events, sibling);
if (prev && prev->next)
{
display->queued_events = g_list_insert_before (display->queued_events, prev->next, event);
return prev->next;
}
else
return _gdk_event_queue_append (display, event);
}
/**
* _gdk_event_queue_insert_after:
* @display: a #GdkDisplay
* @sibling: Append after this event.
* @event: Event to append.
*
* Appends an event before the specified event, or if it isn't in
* the queue, onto the tail of the event queue.
*
* Returns: the newly appended list node.
*
* Since: 2.16
*/
GList*
_gdk_event_queue_insert_before (GdkDisplay *display,
GdkEvent *sibling,
GdkEvent *event)
{
GList *next = g_list_find (display->queued_events, sibling);
if (next)
{
display->queued_events = g_list_insert_before (display->queued_events, next, event);
return next->prev;
}
else
return _gdk_event_queue_append (display, event);
}
/**
* _gdk_event_queue_remove_link:
* @display: a #GdkDisplay
@ -1101,13 +1158,16 @@ gdk_synthesize_click (GdkDisplay *display,
gint nclicks)
{
GdkEvent temp_event;
GdkEvent *event_copy;
GList *link;
g_return_if_fail (event != NULL);
temp_event = *event;
temp_event.type = (nclicks == 2) ? GDK_2BUTTON_PRESS : GDK_3BUTTON_PRESS;
gdk_display_put_event (display, &temp_event);
event_copy = gdk_event_copy (&temp_event);
link = _gdk_event_queue_append (display, event_copy);
}
void