Re: glib+orbit
- From: bob cs csoft net
- To: Owen Taylor <otaylor redhat com>
- cc: gnome-devel-list gnome org, gtk-doc-list redhat com
- Subject: Re: glib+orbit
- Date: Sun, 9 Jan 2000 17:40:28 -0600 (CST)
On 9 Jan 2000, Owen Taylor wrote:
>
> bob@cs.csoft.net writes:
>
> > On 9 Jan 2000, Owen Taylor wrote:
> >
> > >
> > > bob@cs.csoft.net writes:
> > >
> > > > I am trying to get a g_timeout to work with orbit. I have looked through
> > > > the gconf code, and kinda figured out to do it, but it seems very genaric.
> > > > why is this code not in orbit itself?
> > > >
> > > > also, a GMainLoop question.
> > > > in gconfd, the global var main_loops is defined. Why does it exist? I
> > > > spent the last few hours trying to figure out how GMainLoop works (there
> > > > is like no dox on it), and it looks like there can only ever be one main
> > > > loop, so why does main_loops exist? (or was this code copied out of gtk,
> > > > the only other place I could find it?)
> > >
> > > http://developer.gnome.org/doc/API/glib/glib-the-main-event-loop.html
> >
> > I read that already. desnt say anything but how to create a new main loop.
> > (doesnt mention that there is only one ever really created).
>
> To quote:
>
> The GMainLoop data type represents a main event loop. A GMainLoop is
> created with g_main_new(). After adding the initial event sources,
> g_main_run() is called. This continuously checks for new events from
> each of the event sources and dispatches them. Finally, the processing
> of an event from one of the sources leads to a call to g_main_quit()
> to exit the main loop, and g_main_run() returns.
>
> It is possible to create new instances of GMainLoop recursively. This
> is often used in GTK+ applications when showing modal dialog
> boxes. However, all event sources are global; they are not tied to a
> particular GMainLoop.
>
> I'm not really sure isn't there that you'd want to see. But if you have
> suggestions on how the text could be improved we'd appreciate hearing
> about it. :-)
>
> (Actually, the text is a little unclear, in that the first part sounds
> like event sources are associated with a particular GMainLoop, and then
> that is only clarified in the second paragraph.)
Well, in hind site, the text kinda makes sence, but it is, like you said,
alittle unclear. The thing that confused me, was creating a GMainLoop.
The way the functions looked were similar to how threads look. It looks
like the loop that is returned is more then just the place holder that it
is. I am very poor at english, so I dont know how to clerify any farther.
sorry. anyway, thanks anyway. :)
>
> > I had to go
> > through the glib cvs tree with lxr (great little tool btw) and trace half
> > a duzzen functions to find out how it worked. wasnt pritty. :)
> >
> > Thanks though. I got it to work like I wanted about 10 min ago. :)
>
> Regards,
> Owen
>
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]