[BUG] cannot open the fun With morphic projects

Boris Gaertner Boris.Gaertner at gmx.net
Sun Mar 28 20:04:40 UTC 2004


"stéphane ducasse" <ducasse at iam.unibe.ch> wrote:


> Hi
>
> When I click on the Fun with Morphic project in a 5816 downloaded from
> the web, squeak blocks.
> do I am the only one?

No, you are not. I can open the project only after I reverted to
an earlier version of  MagnifierMorph>>magnifiedForm.

The problem is that a a new instance variable was
added to MagnifierMorph and it is assumed that this
instance variable always holds a boolean variable.
However, in the old instance of the MagnifierMorph,
the new variable has the value nil.

You can also do this (before you try to enter the project):

MagnifierMorph allInstances do:
  [:m |m showPointer: true].

When you have done this, you can enter the project.
This should fix the problem. I think we should propose
this as a fix for the update stream. What dou you think?

A third possibility follows the guidelines of
"defensive programming": In
MagnifierMorph>>magnifiedForm
we read:

(RecursionLock isNil and: [ showPointer or: [ srcRect intersects: self
bounds ]])
  ifTrue: [ < ...> ]

showPointer = true

would be save even for nil values.

Greetings, Boris






More information about the Squeak-dev mailing list