Re: gdk_threads_enter/leave() in threaded and non threaded situation

2005-02-13 Thread Pablo
() in threaded and non threaded situation hi hi, I have a gobject property that is set (via g_object_set()) from within a thread and from the main thread. Further I have signal handlers that watch this via notify::property. These signal handler call gtk functions. Therefore in these signal handlers

Re: gdk_threads_enter/leave() in threaded and non threaded situation (SOLVED)

2005-02-12 Thread Stefan Kost
just a closing follow up. I found a solution in rythmbox sources : static GThread *main_thread = NULL; void rb_thread_helpers_init (void) { main_thread = g_thread_self (); } gboolean rb_thread_helpers_in_main_thread (void) { return (main_thread == g_thread_self ()); } void

Re: gdk_threads_enter/leave() in threaded and non threaded situation

2005-02-11 Thread Tristan Van Berkom
On Fri, 11 Feb 2005 09:46:41 +0200, Olexiy Avramchenko [EMAIL PROTECTED] wrote: Stefan Kost wrote: hi hi, Hello I have a gobject property that is set (via g_object_set()) from within a thread and from the main thread. Further I have signal handlers that watch this via notify::property.

Re: gdk_threads_enter/leave() in threaded and non threaded situation

2005-02-11 Thread Stefan Kost
Hi hi, it is still not that simple :( I have a core lib, that is used by a commandline and by a gtk based app. All is gobject based. In the core lib I have an object A that has a property A.a. Now from the gtk app I set this property from a thread (when playing) and from my main thread (via user

Re: gdk_threads_enter/leave() in threaded and non threaded situation

2005-02-11 Thread Stefan Kost
another go in trying to make the situation clear. I have two place in the source that is causing the notify signal to be emited: A) core lib :: sequence.play() * when called from a gtk app it will run inside a thread * the method directly changes the property and calls g_object_notify() B)

Re: gdk_threads_enter/leave() in threaded and non threaded situation

2005-02-11 Thread Tristan Van Berkom
On Fri, 11 Feb 2005 19:06:44 +0100, Stefan Kost [EMAIL PROTECTED] wrote: [...] The g_object_set() is called from a signal callback that gets triggered by user action and thus already runs gdk_mutex protected. Wrapping this with enter/leave would block. I can wrap the g_object_notify() with the

Re: gdk_threads_enter/leave() in threaded and non threaded situation

2005-02-10 Thread Peter Bloomfield
On 2005.02.10 16:20, Stefan Kost wrote: hi hi, I have a gobject property that is set (via g_object_set()) from within a thread and from the main thread. Further I have signal handlers that watch this via notify::property. These signal handler call gtk functions. Therefore in these signal

Re: gdk_threads_enter/leave() in threaded and non threaded situation

2005-02-10 Thread Olexiy Avramchenko
Stefan Kost wrote: hi hi, Hello I have a gobject property that is set (via g_object_set()) from within a thread and from the main thread. Further I have signal handlers that watch this via notify::property. These signal handler call gtk functions. Therefore in these signal handlers the gtk part