Adam D. Moss writes:
 > >  * app/cursorutil.c (gtkutil_compress_motion)
 > >  * app/edit_selection.c (process_event_queue_keys): Guard against
 > >  gdk_event_get returning NULL (which can happen at least on Win32).
 > I'd kinda like to see this reverted and fixed at the WIN32 GDK level
 > -- if gdk_event_get() fails straight after a gdk_events_pending()
 > succeeds in a single-threaded app then it's not just GIMP that's
 > going to have a problem...

 > ...unless this is documented cross-platform behaviour, of
 > course!  Tell me if I missed something.

IMHO this could well happen on X11, too. After all, gdk_events_pending()
just checks for (gdk_event_queue_find_first() || XPending(gdk_display)). If
the event queue is empty, but XPendig() returns TRUE, that still doesn't
mean that any of the X events that are waiting will necessarily generate
any GDK event, does it? If gdk_event_translate returns FALSE, no GDK event
will be put on the queue.

Presumably this doesn't happen very often on X11, where windows can select
what X events they are interested in, and those event classes happen to
correspond pretty closely to GDK's ;-). But, on Win32 there isn't any way
to select what classes of messages to receive, and there are lots of
messages that Windows sends that GDK isn't interested in at all.


Reply via email to