[Seaside] Receiving the Answer of a Child Component?

Andrius Paulavicius apaulavicius at gmail.com
Sat Jun 9 18:02:39 UTC 2007


Components can intercept answers of child component. You should add something 
like "self onAnswer: [:ans | self answer: ans]" to GHWelcome initialize

> Newbie alert, folks.
> 
> My root component is a subclass of WATask (named GHStart), and the
> first move in my workflow is basically this:
> 
> user := self call: (GHWelcome new)
> 
> GHWelcome renders two child component: one that allows users to
> register, and one that allows them to login.  Might as well serve both
> on one page, right?
> 
> So, the essence of my problem:  when a user logs in or creates a new
> account, those child components need to return the user object,
> causing the GHWelcome instance to #answer the originating #call from
> the instance of GHStart.
> 
> Any ideas as to how I can do this?  Please be gentle, as I am rather
> new to Smalltalk in general (I hail from Ruby).  There might already
> be a tutorial that I am missing, or this may have already been
> answered on the list before, I just don't know the right thing to
> search for.
> 
> It seem inappropriate to have the children talk to the parent,
> GHWelcome, as that pretty much throws the idea of reusability out the
> window...
> 
> Thanks,
> 
> Michael Gorsuch
> 
> -- 
> Styled Bits 2.0: They're Mostly Broken, But I Try
> http://www.styledbits.com
> _______________________________________________
> Seaside mailing list
> Seaside at lists.squeakfoundation.org
> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside


More information about the Seaside mailing list