Re: progress bar doesn't pulse...
- From: Tristan Van Berkom <vantr touchtunes com>
- To: baver thebeever com
- Cc: Bart Vandewoestyne pandora be, gtk-app-devel-list gnome org
- Subject: Re: progress bar doesn't pulse...
- Date: Fri, 01 Aug 2003 09:27:17 -0400
Richard Baverstock wrote:
If I remember correctly, I was trying to do something similar and was
advised not to use gtk-specific functions in a thread -- instead, send a
message back to the main thread and have a function that is called then
which updates the progress bar. I can't remember why though ... can
someone else enlighten us?
This aproach is no longer nescisary but IMO still is good practice.
Updating the GUI from multiple threads just becomes a critical section.
there has been a mutex set in place for this which is locked/unlocked
in some places in the library (stays locked while the main loop does whatnot
and unlockes for the marshaling of callbacks et al... also unlocks when
idle)
try [ grep GDK_THREADS_ENTER `find gtk_libs/ -name "*.c"` ] to see
exactly what gets protected.
Cheers,
-Tristan
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]