At 12:01 PM 7/30/2002 -0400, Howdy-Tzi wrote:

> >Then in the closeMiaw handler which is on your stage, have the code
> >to close and forget your Miaw.
>
>No no no. Sending the call like that will result in serious and
>painful death on some but not all Windows systems. Here's the only
>clean way I've managed it.

I have used it for a massive project just recently and as of yet have yet 
to face problems as you mention.  Maybe I've just been plain lucky :)

>1. Stage has a sprite that's got a window manager behavior. On
>beingsprite this inits the window. On endsprite it forgets it.
>
>2. Window has the close button that sends a call to the stage's
>window behavior, telling it to set a close flag to true.
>
>3. On the next frame cycle the stage's behavior checks its flag, sees
>it's marked true, and forgets the window.
>
>Because Lingo exits one handler temporarily to run another, and then
>returns to the jump-out point when the second handler is finished, a
>tell the stage call issuing a close window command has the same
>effect as disposing the window directly within itself, which means
>(on Win anyway) your program terminates abnormally.

Your method is definitely better than mine. Robust is a better word for it.
I'll make it a point to modify/change my code accordingly.

> >Another way would be to use your projector exit handler to go
> >through the 'windowlist' and forget all instances of any MIAW's.
>
>I don't believe the windowList has ever been 100 percent accurate, so
>that method might not work either. The best method is to always know
>what windows are open, and which ones you are closing.

And that's why I said it's not really recommended.

Thanks for your inputs. Much appreciated.

Mayuresh

[To remove yourself from this list, or to change to digest mode, go to 
http://www.penworks.com/lingo-l.cgi  To post messages to the list, email 
[EMAIL PROTECTED]  (Problems, email [EMAIL PROTECTED]). Lingo-L is for 
learning and helping with programming Lingo.  Thanks!]

Reply via email to