quitting is too complicated
Björnke von Gierke
bvg at mac.com
Tue Jul 3 16:21:37 EDT 2007
I seldom make applications, but I've run into these problems when I
tried to make my first os x standalone this year:
1. command-q does never produce closestackrequest.
2. closing the stack does leave the application running (as long as
there is any other stack in memory).
Therefore I had to use three messages (reposted below). Please someone
tell me that I missed the one correct message for intercepting quitting
and saving a stack :(
on closeStackRequest
if the environment <> "development" then
quit
end if
pass closeStackRequest
end closeStackRequest
on shutdownRequest
if the environment <> "development" then
save this stack
end if
pass shutdownRequest
end shutdownRequest
on appleEvent theID, theEvent
if theID = "aevt" and theEvent = "quit" and the environment <>
"development" then
save this stack
end if
pass appleEvent
end appleEvent
--
official ChatRev page:
http://chatrev.bjoernke.com
Chat with other RunRev developers:
go stack URL "http://homepage.mac.com/bvg/chatrev1.3.rev"
More information about the use-livecode
mailing list