That's the reason for
winEnterEvent winExitEvent
I guess. See SDK40-examples\Examples\Reptoids\Src\Rocks.c line 8465
Regards Henk
Logan Shaw wrote:
Terry Young wrote:
I have my time displayed up close the the title of my form. When I open a menu it covers the time field. When the time field updates it will appear in the menu. How do I prevent it from doing this.
I had something similar happen with an animation. It seems what's going on is that the menu is a separate draw window, but Palm OS still sends events (including nilEvents, which I was using to trigger animation frames) to the current form's event handler.
I solved this problem by saving the current draw window in a variable right after I open the form:
FrmDrawForm (); properdrawwindow = WinGetDrawWindow();
Then when it is time to draw the window, I do this:
if (WinGetDrawWindow() == properdrawwindow) { /* draw the stuff here */ }
Since you are updating the clock infrequently, you might also want to put in an else clause that sets some flag saying you missed one of the "heartbeats" and should draw immediately next time you get a chance. As far as I know, there is no way to have the system inform you when a menu disappears in the general case. You can only have it inform you when someone selects something from a menu.
- Logan
-- ------------------------------------------------------------------------- Henk Jonas [EMAIL PROTECTED] Palm OS � certified developer
Please contact me, if you need an off-side contract worker. -------------------------------------------------------------------------
-- For information on using the Palm Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/support/forums/
