Re: Threads
- From: Russell Shaw <rjshaw iprimus com au>
- Cc: gtk-app-devel-list gnome org
- Subject: Re: Threads
- Date: Tue, 02 Dec 2003 01:27:47 +1100
Russell Shaw wrote:
Olexiy Avramchenko wrote:
Russell Shaw wrote:
Hi,
Does g_timer_start() need to be surrounded with gdk_threads_enter()
and gdk_threads_leave() in my own thread?
Hello,
The call itself doesn't need it. You probably may need it if you
creating timer async. in another thread, but I really can't imagine
this case.
ok. I also have a function that is called from a normal gtk callback, as
well as other threads. This function calls gtk things, so it has
gtk_threads_enter()/gtk_threads_leave() in it.
When the function is called from the normal gtk callback, it gets blocked
on gtk_threads_enter(). Why? I have disabled all other threads.
I fixed it by doing: gdk_threads_leave() -> function() -> gdk_threads_enter()
from within the gtk thread.
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]