[bug] Connectors or Stack Morph?

Ned Konz ned at bike-nomad.com
Sat Oct 11 19:30:33 UTC 2003


On Saturday 11 October 2003 06:50, David Faught wrote:

> With a stock 3.5 image on Windows and Connectors 1.9 freshly loaded
> from SqueakMap, here is how to recreate this problem:
>
> 1. Put a Stack morph on the screen (from the Objects morph Presentation
> pane, for example)
>
> 2. On the Stack morph page, build a simple diagram, such as two Basic
> Shapes connected by a connector (all from the Connectors flap)
>
> 3. Add a new page to the Stack morph
>
> 4. When you go back to the page with the simple diagram, the connector
> has become unconnected at both ends.
>
> I tried this with a Book morph and it works fine, only the Stack morph
> seems to be a problem.
>
> This is not terribly pressing as far as I am concerned, and I know you
> have said something about a new version coming out soon, but I thought
> I would point this out.

My new stuff does this too. Here's why:

When you switch away from a page, the morphs on the background get deleted and 
held in the CardPlayer's privateMorphs collection.

And when Connectors get deleted (or when what they're connected to gets gc'd) 
they disconnect themselves.

I think if I were doing it, I'd probably consider keeping the PasteUpMorph 
around (or moving all the morphs into a private container temporarily).

Actually, a better solution might just be to use removeMorphs: which is 
provided by Andreas' MorphRemoval changeset. It lets you remove morphs 
without deletion.

Anyway, Scott may be able to shed some light on this.

-- 
Ned Konz
http://bike-nomad.com
GPG key ID: BEEA7EFE



More information about the Squeak-dev mailing list