Re: [Pharo-users] Morph reacting to Window being closed

2018-08-07 Thread Peter Uhnák
Thank you Henrik, #outOfWorld: was the best solution to me, as I can use it even when I don't control the window/container the morph is embedded in. Peter On Sun, Jul 29, 2018 at 10:16 PM, Henrik-Nergaard wrote: > Hi Peter, > > There are two methods which can be used for this purpose. >

Re: [Pharo-users] Morph reacting to Window being closed

2018-07-29 Thread Henrik-Nergaard
Hi Peter, There are two methods which can be used for this purpose. #outOfWorld: #announceDeleted Both are called recursively down the morph tree from the window. If you need to stop the window or provide a dialog then you should create a subclass of Model and use that to keep references to

Re: [Pharo-users] Morph reacting to Window being closed

2018-07-29 Thread Hilaire
Hi Peter, I think you have two options: 1. Specialize the Window and use your own delete method to do your additional cleaning. This is what I do in Dr. Geo. 2. Use the WindowClosed announcement from system window to catch the signal from the morph you want to clean Hilaire Le 29/07/2018 à