Re: g_hash_table_steal_extended()

2006-11-18 Thread muppet
On Nov 18, 2006, at 1:51 PM, Ken Ishii wrote: > if (g_hash_table_steal_extended (hash_table, key, &value)) A nice idea, but "extended" isn't a great name. How about "steal pair"? ___ gtk-devel-list mailing list gtk-devel-list@gnome.org http://mail.gno

g_hash_table_steal_extended()

2006-11-18 Thread Ken Ishii
Hi, When you want to steal a key/value pair from a GHashTable and at the same time retrieve the pair's value, doing something like value = g_hash_table_lookup (hash_table, key); g_hash_table_steal (hash_table, key); requires hashing the same key twice. So instead, something like if (g_hash_tabl

Re: GEvent - Proposal for a new threading structure for GLib

2006-11-18 Thread Matthew Barnes
On Fri, 2006-11-17 at 12:27 -0500, [EMAIL PROTECTED] wrote: > Isn't this what a semaphore is? A GEvent is essentially a binary semaphore, yes. With perhaps a more intuitive name. > I would suggest that somebody look at what the full requirements are, > and not mimic Python. :-) > > I think a s

Re: GEvent - Proposal for a new threading structure for GLib

2006-11-18 Thread Tristan Van Berkom
Olexiy Avramchenko wrote: >On 11/17/06, Matthew Barnes <[EMAIL PROTECTED]> wrote: >... > > >>I've attached a patch that implements and documents GEvent. It closely >>mimics the Python class, so I won't bother describing the API here. >> >> > >Is GCond not suitable for this purpose? > > Ye

Re: GEvent - Proposal for a new threading structure for GLib

2006-11-18 Thread Matthew Barnes
On Sat, 2006-11-18 at 15:04 +0200, Olexiy Avramchenko wrote: > Is GCond not suitable for this purpose? Not by itself, no. You also need a mutex and an actual condition to watch for. GEvent uses a GCond internally. Matthew Barnes ___ gtk-devel-list ma

Re: GEvent - Proposal for a new threading structure for GLib

2006-11-18 Thread Olexiy Avramchenko
On 11/17/06, Matthew Barnes <[EMAIL PROTECTED]> wrote: ... > I've attached a patch that implements and documents GEvent. It closely > mimics the Python class, so I won't bother describing the API here. Is GCond not suitable for this purpose? Olexiy

Re: [Tracker] Filechooser search support

2006-11-18 Thread Mikkel Kamstrup Erlandsen
2006/11/17, Matthias Clasen <[EMAIL PROTECTED]>: I have put an updated patch for filechooser search support in http://bugzilla.gnome.org/show_bug.cgi?id=344785 It is a port of the NautilusSearchEngine framework and supports both beagle and tracker, as well as a simple ftw()-based search. It w