Croquet/Morphic question

Joshua 'Schwa' Gargus schwa at cc.gatech.edu
Fri May 16 15:07:15 UTC 2003


Hmm, I'm a bit confused by this.  I'm back in a regular Squeak image.  I've
put halts at the beginning of B3DSceneMorph>>[into/outOf]World:  

No halt occurs when I delete/collapse a PasteUp containing the b3d morph.
However, a halt occurs when the PasteUp is expanded or send openInWorld;
the halt occurs in #intoWorld: as expected.

However, everything works!  Even though the b3d morph does not receive
#outOfWorld:, it still stops displaying!  Oh, wait... I didn't enable
the hardware acceleration.  <click> Ok, now it is broken, as expected.
Did this definitely work at some time?  I'll dig back in my image archive
and check.

Best,
Joshua


On Fri, May 16, 2003 at 01:50:09PM +0200, Andreas Raab wrote:
> Hi Josh,
> 
> The #outOfWorld: protocol is supposed to take care of this. E.g., when a
> morph disappears from the screen it sends #outOfWorld: to all of its
> children. I'm somewhat surprised to hear that the Teapot doesn't handle this
> appropriately (but then I haven't tested this ;-) Have a look B3DSceneMorph
> which should handle this correctly.
> 
> Cheers,
>   - Andreas
> 
> > -----Original Message-----
> > From: squeak-dev-bounces at lists.squeakfoundation.org 
> > [mailto:squeak-dev-bounces at lists.squeakfoundation.org] On 
> > Behalf Of Joshua 'Schwa' Gargus
> > Sent: Friday, May 16, 2003 8:17 AM
> > To: Squeak Mailing List
> > Subject: Croquet/Morphic question
> > 
> > 
> > Hi,
> > 
> > Is there a way to notify morphs that someone in their owner chain has
> > been deleted/collapsed?  The reason I ask is that I want to make a
> > morph that contains a (subclass of) TeapotMorph.  However, when I
> > delete or collapse my prototype, the TeapotMorph is not notified and
> > its glx continues to render on the screen.  I can imagine that there
> > might be other non-OpenGL situations where a submorph might want some
> > notification.
> > 
> > One way I see is to have a deleted/collapsed morph call #triggerEvent:
> > on itself and the entire tree below it.  Morphs that care could
> > register a response with themselves.  Another way would be to just
> > call #triggerEvent: on the deleted/collapsed morph, and have
> > interested submorphs register with it.  This has a problem: if the
> > widget is dropped into a PasteUpMorph which is then deleted, the
> > interested morph won't be notified.
> > 
> > Any other ideas?
> > 
> > Thanks,
> > Joshua
> > 
> 



More information about the Squeak-dev mailing list