ActiveGlobals explained by Andreas Raab

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

ActiveGlobals explained by Andreas Raab

David T. Lewis
In the course of trying to better understand the role of the ActiveHand
global, I found an excellent explanation by Andreas Raab in his original
change set. I put this on the swiki and linked it to several related pages:

  http://wiki.squeak.org/squeak/6647

It is amusing to note how I found this. I was trying to figure out what
object should properly own the active hand, and I had conviced myself
that it should probably be the WolrdState for a Morphic world.

So as an experiment, it tried adding the instance variable to WorldState,
and I discovered to my surprise that it was already there. It was completely
unreferenced, but one of my Morphic worlds still had it set to point to
a HandMorph, which seemed odd.

Looking back at old images, I found that the activeHand instance var in
WorldState was last used in Squeak 3.0, and that the global variable that
replaced it was in use as of Squeak 3.10.2.

A bit of digging though the files.squeak.org archives led me to the
original change set in which the change was made. Andreas provided a
preamble with explanation of the rationale for the change, this this
is what I copied to the swiki.

Despite the fact that a WorldState instance still point to an activeHand,
that reference has apparently been hanging around for the last 20 years
without actually being used for anything.

Dave