[squeak-dev] [MC] unload action and postload actions

Matthew Fulmer tapplek at gmail.com
Sat Oct 11 15:40:04 UTC 2008


On Sat, Oct 11, 2008 at 03:31:15PM +0100, Keith Hodges wrote:
> Alexandre Bergel wrote:
> > Dear List,
> >
> > I was wondering whether there is a way to specify unload action and
> > postload actions when saving a monticello package?
> >
> > Cheers,
> > Alexandre
> There is a "Scripts" button in the Monticello Browser. This is supported
> by Monticello 1.0 , but it depends upon whether or not the loaded
> version of PackageInfo supports it.
> 
> Monticello 1.5/1.6 as loaded by
> http://installer.pbwiki.com/LevelPlayingField support them. The scripts
> are added as properties of PackageInfo.
> 
> There additional hooks in MC1.5 however you add the code as class
> methods, and you can add the code as a class method on someone elses
> package if you want to add/remove instVars to someone elses class
> 
> Methods are named like so: #mcAfterInstall* #mcAfterRemoval*
> #mcOnInstall* #mcOnUninstall*

Also, anytime a class is removed, it's #unload method is called,
just like it's #initialize method is called on load

-- 
Matthew Fulmer -- http://mtfulmer.wordpress.com/



More information about the Squeak-dev mailing list