[squeak-dev] Re: Handle Close Event in Image - necessary for 1.0?

Andreas Raab andreas.raab at gmx.de
Thu Apr 15 22:56:59 UTC 2010

Hi -

Just as a reminder when you discuss VM stuff, make it a habit to include 
vm-dev at lists.squeakfoundation.org. I don't read the Pharo list regularly 
(I only checked it today due to the unfortunate Scratch development). 
This whole issue was entirely unnecessary and could've been solved with 
one message to vm-dev. Here is why:

The in-image close-event that is now generated by default in the Windows 
VM has always been a settable entity. If you'll compare the 4.0.2 vs. 
3.11.8 VMs the only difference in this area is that the preference 
"EnableAltF4Quit" is now unset by default. To change it, edit your .ini 
file to have:

   EnableAltF4Quit = 1

and you will be back to the previous behavior. You can add this 
trivially to your one-click (or other) setup. In fact, I'd recommend 
going carefully through the other relevant vm settings and decide how 
they should be set for your releases. They are documented here:


So next time, do include vm-dev when you have a vm issue.

Thanks for listening,
   - Andreas

On 4/6/2010 3:22 AM, Torsten Bergmann wrote:
> I think I've found something that should be fixed
> before releasing 1.0 since it is meanwhile a major problem on Windows.
> In "old" Squeak/Pharo you could close the native world window
> using the "X" or hit ALT+F4 on Windows and the system
> asked you if you really want to close the whole Smalltalk system
>   using a native dialog which was provided by the VM.
> With the new VM's (4.0.1 and 4.0.2 on Windows, see [1]) the native
> "window close event" is now dispatched from the VM into
> the image so it could be handled by Smalltalk code.
> This is currently not done/handled in Pharo. Only in Squeak so far.
> The recent Squeak trunk/release candidate already handles the
> event within the image and now provides an in-image dialog
> to ask the user to quit.
> So: in Pharo now NOTHING happens when you try to close the window
> using "X", you can only quit using the world menu - which is IMHO really
> a show stopper since you cant close using "X" or ALT+F4 (the key combination to close any windows program).
> Two possible options:
> A) we should handle the event now in-image similar to Squeak
>     by fixing and integration issue 2131 (see [2]), so not only
>     for 1.1. but also for 1.0
> B) release and distribute Pharo 1.0 with an old VM<  4.0
> BTW:
> You can get the old behavior on Windows by additionally using SHIFT, so
> SHIFT + ALT + F4 allows to close.
> But this is not very convinient, doesnt follow what the typical
> Windows user expects and one has to know about it...
> Bye
> T.
> [1] http://lists.squeakfoundation.org/pipermail/vm-dev/2010-March/004142.html
> [2] http://code.google.com/p/pharo/issues/detail?id=2131

More information about the Squeak-dev mailing list