[comp.sys.mac.hypercard] close palette help from Scot Kamins

mikef@bbs.acs.unc.edu (Michael Freedburg) (02/28/91)

>HOW do I tell when the user closes the palette?

on closePalette
  put "Palette is closed!"
end closePalette

Strangely enough, HyperCard sends closePalette to the current card when you
(yes) close a palette!   :-}   I found this out this very afternoon!  
Seriously!

 

-- 
Scot Kamins         Co-author, "HyperTalk 2.0: The Book"
(415) 282-8872                        (with Dan Winkler)      
671 28th Street            San Francisco           94131
kamins@kumr.lns.com                      kamins@wet.UUCP
******
First of all, I *really* like the fact that Scot himself has bothered to
answer this question, but then I thought "Was he making fun of me?" How
could he, the co-author of the only other book next to my bed (besides
Red Dragon by Thomas Harris, really scary!!!!!) not know about a
HyperTalk message being sent by the palette?? What I do not understand,
however, is why this message does not show up in the Message Watcher?
What messages should we expect to find in the Message Watcher, and is it
the case that xcmds and xfcns are not properly posting their messages to
the message queue or what?
Scot, thanks for the help, and one last thing:
excellent tux, man!!
Love and Peace
mikef@samba.acs.unc.edu

sumner@opusc.csd.scarolina.edu (David Sumner) (03/07/91)

Scot Kamins Writes
 >Strangely enough, HyperCard sends closePalette to 
 >the current card when you (yes) close a palette! 
  > :-}   I found this out this very afternoon!
 >Seriously!
 
Curiously, ClosePalette is not sent when just any palette 
is closed. Try for instance going to the Power Tools stack 
and closing the "List of Tools" palette (after it is opened). 
No close palette message is sent. Now go to the 
Window Manager card and click on the "Show Palette"J
button. When you close this Window Mgr. Palette, a 
ClosePalette message is sent (and you'll see it in the 
Message Watcher.
David Sumner

If you ask a fish to describe its environment, the last
 thing it mentions is water.