Re: Timers in GTK
- From: G Hasse <gh raditex se>
- To: Petro Verheuvel <pverheuvel zonnet nl>
- Cc: <gtk-app-devel-list gnome org>
- Subject: Re: Timers in GTK
- Date: Mon, 4 Feb 2002 17:40:32 +0000 (GMT)
On Sat, 2 Feb 2002, Petro Verheuvel wrote:
Hi there,
I have an application using setitimer(). I want to integrate this in GTK.
GTK has some timer-capabilities too. Can these timer concepts be
simultaneously used, or should i omit the use of setitimer() in GTK ?
It is my strong opinion that you should try to avoid all strict
timeing in your UI.
Make a separate process and let this notify your UI when it has
completed. (Preferable by a file descriptor. And you add a callback with
gdk_input_add( fd, GDK_INPUT_READ, GTK_SIGNAL_FUNC(file_function),
&cmdinfo );
So when your background process put data to fd the UI will go to
"file_function" and process this. If you make fd a socket you could
even distribut your background process.
GH
----------------------------------------------------------------
Göran Hasse email: gh raditex se Tel: 08-6949270
Raditex AB http://www.raditex.se
Sickla Alle 7, 1tr Mob: 070-5530148
131 34 NACKA, SWEDEN
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]