Re: cos we really need another chat system...

From: Date: Fri, 09 Nov 2001 14:35:54 +0000
Subject: Re: cos we really need another chat system...
References: 1  Groups: php.gtk.general 
Request: Send a blank email to php-gtk-general+get-547@lists.php.net to get a copy of this message
Simon Wheeler wrote:
NO worries , Its just for part of my learning process (a slow one at that) and a project to play with. So I am making a chat app with PHP-GTK, but I need to periodically ask the server for information and grab the latest XML file/whatever. So I need a loop that every $x seconds runs a function. This I can achieve , but not without freezing the whole app, I mean its working... and refreshing the data but I can not actually use the app when this is happening, which is all the time :), using sleep() for timing etc does exactly that. Any ideas/examples would be much appreciated.
I guess the 'while (gtk::events_pending())'    thingy (I think thats the technical term for it)  is going to be mentioned again , which is a shame as I have had no success (or errors!) using it.
http://gtk.php.net/manual/en/gtk.method.idle_add.php http://gtk.php.net/manual/en/gtk.method.timeout_add.php there is a bit of an example at the end of http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/phpmole-ide/phpmole/dialogs/phpide.class?rev=1.2&content-type=text/vnd.viewcvs-markup the commented out gtk::timeout_add(15000, 'dummy_timer'); -- Linux Center Hong Kong Ltd. - Center of Excellence The next generation OS available now. www.hklc.com alan_k@hklc.com www.hklc.com/infocenter Alan's Linux Infocenter

« previous php.gtk.general (#547) next »