Possible to get applicationMain object at runtime?

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Possible to get applicationMain object at runtime?

Rick Flower
Normally I'd like to keep most session values in my session class --  
however, I've got a 'content' object that will render whatever object  
is in it -- but this lives within the application which is doing the  
main rendering.. Is there any easy way to gain access to that from  
anywhere within the system?  This way as I burrow deeper into menus, I  
can tell the top-level application what object needs to be rendered  
next.. I realize I could put this in the session class but then the  
header/footer/content objects are split between two classes --  
something I'm trying to avoid.

Thanks!

-- Rick

P.S. Happy Early New Year!
_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: Possible to get applicationMain object at runtime?

Philippe Marschall
2008/12/31, Richard E. Flower <[hidden email]>:
> Normally I'd like to keep most session values in my session class --
> however, I've got a 'content' object that will render whatever object
> is in it -- but this lives within the application which is doing the
> main rendering.. Is there any easy way to gain access to that from
> anywhere within the system?

Pack it into a thread-local or a dynamic variable. You can make your
own custom subclass of WADynamicVariable and use this.

Cheers
Philippe
_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside