Startup/shutdown - random thoughts

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

Startup/shutdown - random thoughts

Schwab,Wilhelm K
The Squeak startUp and shutDown lists are notified with resuming and quitting flags, respectively.  Behavior has #startUp: and #shutDown: methods that forward to #startUp and #shutDown without the flags.

It might be enough to make those forwards conditional, such that the startup and shutdown work occurs only if something really changed.  Forwarding when resuming and when quitting comes to mind, but that seems almost too easy though.  I also see "quit and not resuming" in the snapshot code, which might be a warning to the wise.

OSPlatform is not terribly far away from Dolphin session managers, but it appears not to be widely used, at least for shartup and shutdown.  It also understandably uses inheritance to differentiate the operating systems, and session managers use it to differentiate the IDE vs. desktop and console apps; so they probably should be separate anyway.

Having a lot of code written in terms of SessionManager, I am going to build one to see if I can get the correct behavior.  The tricky part might be to confirm that it works as intended; OutputDebugString might do the job on Windows.  I appear not to be alone in wondering whether there is an equivalent on Linux - there is then some mention of syslog() and using tail to retrieve it; the latter is familiar.

Another thing to consider is that Dolphin also uses levels of startup.  For a while I did something to add a level that was guaranteed to happen after the event loop was established, but OA eventually addressed the associated problems. IIRC my code more or less worked regardless of that change, but something similar will no doubt arise here; #wakeTopWindowUponStartup appears suggestive of it.

If any of this makes sense to you, please speak up :)

Bill


_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project