Re: [xstep-devel] broadcast++ correct version...
Brought to you by:
marcelos
|
From: Marcelo S. <mar...@bs...> - 2002-10-13 22:38:38
|
yes, but in the version 4.0 you have a direct control of event loop. when you have a non-animated application, you can just use: while(XSCheckEvent(desktop,XS_BLOCK)); and you application will work like a version 3.x application with animation=0. if you have a animated application, like a game or a video player, you can use: while(XSCheckEvent(desktop,!XS_BLOCK)) usleep(1); in this case, !XS_BLOCK of version 4.0 is just like animation=1 of version 3.x. but in version 3.x you have a implicit usleep(1) in library code, in the version 4.0 you can decide if you have this usleep() or not. of course, you will need a usleep() to control the rate of your event loop, for example, usleep(1000000/15) to fix a 15 fps loop. but animations and updates are not equal. the broadcast++ equivalent in xstep 4.0 is a desktop->global->count++. of course, this global struct is replicated in any widget, then you can use any wid->global->count++. when a event is checked, the change function of all widgets are checked until cont is zero. marcelo samsoniuk "Tomek G." wrote: > > sorry for that mail it wasn't whole... here is the "good" version: > > Hello, > Is there any equivalent of broadcast++ and animation=1 in xstep-4.0 library? > I need to change label's caption from function: > button_create( -8,-8,72,24,"change", change_label_text ); > Thx, > d0zer > > ------------------------------------------------------- > This sf.net email is sponsored by:ThinkGeek > Welcome to geek heaven. > http://thinkgeek.com/sf > _______________________________________________ > xstep-devel mailing list > xst...@li... > https://lists.sourceforge.net/lists/listinfo/xstep-devel -- You cannot kill time without injuring eternity. |