[Gtk-sharp-list] GUI hangs
Thu, 20 May 2004 08:45:03 -0600
All of your calls to Gtk# have to be from your main thread. I believe
even the timer callbacks will not be on your main thread. There are a
couple of ways around this but I personally have found that ThreadNotify
works the best.
Another option with Gtk# is to use Gtk.Timeout. Basically it will call
back your main thread in the specified number of seconds. Very handy
for updating UI at a specified interval.
On Thu, 2004-05-20 at 16:24 +0200, Tim Rädisch wrote:
> I've a problem using Gtk# and a timer or thread. I need it for something like
> a counter. Every second a value have to be incremented. There are no compile
> errors, and it seems to run.
> But after a while (sometimes seconds, sometimes minutes) the GUI "hangs".
> Everything else works fine. The internal values are changed correct, even a
> Debug.WriteLine(...) before and after jackpotLabel.Text="..." is prompted
> Does anyone know where the problem is?
> Gtk-sharp-list maillist - Gtkfirstname.lastname@example.org