by definition you cannot determine if events are ready without something
semantically equivalent to poll(2). whether or not you block in that
poll-equivalent thing is a different story.

using a main loop that never blocks is a design error. it implies burning
cpu time for no reason, which typically only happens when someone can't
figure how to integrate "another event source" into the main loop. glib
makes this easy for just about kind of event source, so there isn't much of
an excuse for this sort of design.


On Wed, Jun 26, 2013 at 7:21 PM, Kip Warner <k...@thevertigo.com> wrote:

> On Wed, 2013-06-26 at 19:16 -0400, Paul Davis wrote:
> > the OP asked:
> >
> >     Is it possible to wait for GMainLoop event  without processing them?
>
> He said after that that he'd like to avoid a loop with sleep (polling).
>
> > query polls but does not process events. only dispatch does that.
>
> Maybe that's good enough for him, I don't know. But if he doesn't want
> polling, then it won't be.
>
> --
> Kip Warner -- Software Engineer
> OpenPGP encrypted/signed mail preferred
> http://www.thevertigo.com
>
_______________________________________________
gtk-list mailing list
gtk-list@gnome.org
https://mail.gnome.org/mailman/listinfo/gtk-list

Reply via email to