[Seaside] multiple components

Johan Brichau johan at inceptive.be
Sat Feb 4 21:12:17 UTC 2012

For the #call: sites, I don't know any other way than passing the reference to the container. 
But for the #answer: sites, your container component can intercept subcomponents answers [1]. You can use that to propagate an answer from a subcomponent as the answer of the container component.

[1] http://book.seaside.st/book/components/embedding/intercepting-answer

On 04 Feb 2012, at 18:12, Milan Mimica wrote:

> Hello!
>    Some of my more complex views contain a hierarchy of components, each component taking care of some small part of UI logic. This view is implemented as a container component which delegates rendering to several sub-components. From outside, this view looks like an ordinary WAComponent. Everything goo so far. A small problem arises when such component tries to #call: another component. Since technically it is usually the inner component sending #call: to self, the new view doesn't replace the whole hierarchy, but only the inner component that actually sent #call:, which is not fine in this case.
> What am I doing now, is sending each inner component a reference to its container component and then the inner object sends #call: to its container instead of self. I find it ugly, need to elaborate why? Is there a better solution?
> A similar problem arises with #answer -- you cannot #answer from an inner component because it wasn't the one which wall #call-ed in the first place. Again I need a reference to a container component to #answer from there.
> -- 
> Milan Mimica
> http://sparklet.sf.net
> _______________________________________________
> seaside mailing list
> seaside at lists.squeakfoundation.org
> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside

More information about the seaside mailing list