On Sat, 2005-03-26 at 06:46 -0600, Skip Montanaro wrote: > LÃszlÃ> I want to make my application very responsive under high load. > ... > LÃszlÃ> As you can see, I want to pulse a progress bar while a long > LÃszlÃ> (computationally or I/O intensive) operation is running. I > LÃszlÃ> started a separate thread for it. > > I could be wrong (never used threads with gtk), but don't you have some sort > of gtk thread initialization function(s) to call? See if something in > section 20 of the PyGTK FAQ leads to a solution: > > http://www.async.com.br/faq/pygtk/index.py?req=index
gtk.gdk.threads_init() also you can update the progress bar from you thread by calling these two methods to lock the main thread: gtk.gdk.threads_enter() <gui update code here> gtk.gdk.threads_leave() -- J5 _______________________________________________ pygtk mailing list [email protected] http://www.daa.com.au/mailman/listinfo/pygtk Read the PyGTK FAQ: http://www.async.com.br/faq/pygtk/
