Refreshing Photon GUI in a long loop

hi,

I got a long loop and would like to refresh a PtGauge during
this loop. I tried to put a PtSetResource in the loop but all graphics seem
freezed. I also tried to put the PtSetResource in a PtTimer code
but nothing better.

Is there a call like the “DoEvents” one from the window world ?

Thanks for your help

Y.LEROUX <y.leroux@nospam.actris.com> wrote:
: hi,

: I got a long loop and would like to refresh a PtGauge during
: this loop. I tried to put a PtSetResource in the loop but all graphics seem
: freezed. I also tried to put the PtSetResource in a PtTimer code
: but nothing better.

: Is there a call like the “DoEvents” one from the window world ?

: Thanks for your help

Take a look at the Photon Programmer’s Guide. There’s a chapter called
“Lengthy Operations” (since renamed “Parallel Operations”) that should
help you.


Steve Reid stever@qnx.com
TechPubs (Technical Publications)
QNX Software Systems

To make it short, call PtFlush(); in your loop after PtSetResource.
However, it would be better to cut your loop into pieces and execute these
pieces in a PtTimer callback.
Markus

“Y.LEROUX” <y.leroux@nospam.actris.com> wrote in message
news:a3m9f2$q8r$1@inn.qnx.com

hi,

I got a long loop and would like to refresh a PtGauge during
this loop. I tried to put a PtSetResource in the loop but all graphics
seem
freezed. I also tried to put the PtSetResource in a PtTimer code
but nothing better.

Is there a call like the “DoEvents” one from the window world ?

Thanks for your help