[futurebasic] [FB] ON STOP necessary?

Message: < previous - next > : Reply : Subscribe : Cleanse
Home   : February 2004 : Group Archive : Group : All Groups

From: Brian Stevens <brilor@...>
Date: Mon, 2 Feb 2004 22:39:10 -0700
Before I write more code than necessary to solve my current issue, I 
thought you folks could give me some feedback.  Question is: does the 
runtime (appearance) pass a _wndClose event for open windows when QUIT 
is selected. My short example seems to indicate this doesn't 
happen(b20). In PG this was done for you and during my recent 
transition to appearance runtime I haven't run into this specific 
scenario.  Since I have a general FN to dispatch all window closes I 
was hoping the runtime would generate _wndclose events before closing 
the windows. Failing this, I'm thinking about using  ON STOP. Thoughts 
and input very welcome.

thanks...Brian


LOCAL FN DoDialog
DIM AS long action,reference
'---> Get Event Info
action = DIALOG(0)
reference = DIALOG(action)

SELECT action'first figure out what event it was
'------------- Window events --- (id =  window ID) -----------------
CASE _wndClick'window clicked
WINDOW reference'bring it to front
CASE _wndClose'window closed
beep:BEEP
end select
end fn

on dialog fn doDialog
window 1

do
handleevents
until gFBQuit