Re: GLib - MainLoop Behavior



On Sun, 2003-05-11 at 15:39, Nelio Pereira wrote:
> Hi list..
> 
> I have a question about GMailLoop: does it process
> events concurrently or does it process one event
> completely before processing another one?
> 
> Basicaly, my question is if the implementation is
> something like:
> 
> while (1) {
>   select 
>   process event
> }
> 
> or 
> 
> while (1) {
>   select
>   dispatch thread to process event
> }

GLib never creates threads; everything is normally
serialized.

(If you have several threads calling g_main_loop_run()
for the same GMainContext, then you could have multiple
events being dispatched at once, depending on the event
types and other details.)

Regards,
                                 Owen





[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]