[comp.sys.mac.hypercard] How to keep track of top window in SuperCard?

taylorj@yvax.byu.edu (11/21/89)

I need to know when a window is brought to the top in SuperCard.  I can't use
currentWindow() because there's the possiblity of quite a few floating palettes
(both from my project and the runtime editor) actually being on top of the
"top" window.  I've tried using the updateWindow message, but that doesn't do
it either.  OpenWindow doesn't work, because the window may have already been
open.  I'm about ready to put gobs of code all over the place to try to keep
track of things, but I keep thinking I've missed something obvious like an
activeWindow() function.

Anybody got any ideas?


Jim Taylor
Microcomputer Support for Curriculum
Brigham Young University
taylorj@yvax.byu.edu

jeffl@NCoast.ORG (Jeff Leyser) (11/23/89)

In post <925taylorj@yvax.byu.edu>, taylorj@yvax.byu.edu says:
!
!I need to know when a window is brought to the top in SuperCard.  I can't use
!currentWindow() because there's the possiblity of quite a few floating palettes
!(both from my project and the runtime editor) actually being on top of the
!"top" window. 

The function topWindow() returns the id of the current top window,
ignoring palettes.  Makes life very simple (I too have a project that
makes extensive use of palettes.)


				"In other words, we are talking about a species
 				 that has become dependent not just on
				 cannibalism, but on S&M to perpetuate itself."
-- 
Jeff Leyser                                     jeffl@NCoast.ORG