Re: glib main loop without gtk

2008-11-14 Thread James Scott Jr
How to exit the main loop? Stick this in a timer routine and execute it when your ready to shutdown. --g_main_loop_quit(main_loop); -- Also, the following link contains two daemons; a pure glib one, and a pure libc one; including threads, etc... http://mysite.verizon.net/skoona/sitebuildercon

Re: glib main loop without gtk

2008-11-13 Thread Thomas Stover
First thanks to Alexander Semenov, and Emmanuele Bassi for your responses. It took some poking around, but I think get it now. Here is a concept demo for any future searches that find this thread. I'm not sure how to get out of the infinite loop though, since _iteration() returns both TRUE and

Re: glib main loop without gtk

2008-11-13 Thread Emmanuele Bassi
On Wed, 2008-11-12 at 15:20 -0600, Thomas Stover wrote: > So if one wants to use g_io_channels with out gtk (console / server > app), what exactly is the idea? Does glib need an initialization > function called first? only if you use GObject and the rest of the type system - in which case you'll

Re: glib main loop without gtk

2008-11-13 Thread Alexander Semenov
Alexander Semenov wrote: Thomas Stover wrote: So if one wants to use g_io_channels with out gtk (console / server app), what exactly is the idea? Does glib need an initialization function called first? I see the g_main_loop_new() and friends functions, and that part make sense. The thing is g

Re: glib main loop without gtk

2008-11-13 Thread Alexander Semenov
Thomas Stover wrote: So if one wants to use g_io_channels with out gtk (console / server app), what exactly is the idea? Does glib need an initialization function called first? I see the g_main_loop_new() and friends functions, and that part make sense. The thing is g_io_add_watch_full() type

glib main loop without gtk

2008-11-12 Thread Thomas Stover
So if one wants to use g_io_channels with out gtk (console / server app), what exactly is the idea? Does glib need an initialization function called first? I see the g_main_loop_new() and friends functions, and that part make sense. The thing is g_io_add_watch_full() type functions don't have a