[QUESTION]Morph allSubInstances size =>19196 !!

Bob Arning arning at charm.net
Wed Jun 28 15:39:50 UTC 2000


On Wed, 28 Jun 2000 17:03:24 +0200 Karl Ramberg <karl.ramberg at chello.se> wrote:
>I have found 80 SystemWindows, lots of them are browsers.
>Now, how do I kill them ? 
>Most of them have owner nil.
>Some are of course the 'play with me' windows but the rest ??

Karl,

You have several possibilities:

1. Use the PointerFinder
- Close *everything* you don't absolutely need. Especially SystemWindows. Extra especially Inspectors and Explorers
- Do (Smalltalk garbageCollect)
- Do (SystemWindow allInstances do: [ :e | PointerFinder on: e])
- You should get a light magenta window explaining each SystemWindow's reason for being there. Some will be windows in flaps - their contents will look like:

	#World -> PasteUpMorph
	submorphs: Array
	16: FlapTab
	referent: PasteUpMorph
	submorphs: Array
	2: MorphThumbnail
	morphRepresented: SystemWindow'

which says: "The World has a submorph which is a flap tab which has a referent (the flap itself) which has a submorph which is a MorphThumbnail which represents a SystemWindow"

So this SystemWindow is around because it's tucked inside one of the flaps. Sort through the PointerFinder results windows look for oddities (like 60 or 70 that have the same pattern).

The best way to get rid of these (and prevent them from happening all over again) will depend on what's holding them.

2. You could just use an inspector, but it may be more work. Maybe lots more.
-2a SystemWindow allInstances inspect.
-2b In the inspector, select one of the entries that looks bogus.
-2c From the inspector menu choose "objects pointing to this value"
-2d In the resulting inspector, ignore things that look like part of the window. These will have a reference (owner) to the window. Look for something that doesn't look right. Repeat step 2c.
-2e If you finally get to something like a class or Smalltalk, then you have a global that's holding on to the window (however indirectly).

Cheers,
Bob





More information about the Squeak-dev mailing list