RE: Layout Border component problem

2008-12-15 Thread kawes
> entities for onActivate/onPassivate. > > Jonathan > > > > >> -Original Message- >> From: kawes [mailto:rafal.kawe...@gmail.com] >> Sent: Monday, December 15, 2008 12:14 >> To: users@tapestry.apache.org >> Subject: Re: Layout Border co

RE: Layout Border component problem

2008-12-15 Thread Jonathan Barker
pestry.apache.org > Subject: Re: Layout Border component problem > > > Hi Olle, > > I finally got home and was able to check out your suggestion. > Works perfectly but I still have a small question: > > I also used onActivate() to paste your code and it works as well. >

Re: Layout Border component problem

2008-12-15 Thread kawes
Hi Olle, I finally got home and was able to check out your suggestion. Works perfectly but I still have a small question: I also used onActivate() to paste your code and it works as well. So my question is: is it big difference between those methods and can both be used interchangeably or thi

Re: Layout Border component problem

2008-12-15 Thread Olle Hallin
In 5.0.17+ you will get a runtime exception if you try to initialize a page member in the declaration. At least for me it works that way. Olle 2008/12/15 kawes > > Ok found an answer to my second question, > some info is provided here: > http://tapestry.apache.org/tapestry5/tapestry-core/guid

Re: Layout Border component problem

2008-12-15 Thread kawes
Ok found an answer to my second question, some info is provided here: http://tapestry.apache.org/tapestry5/tapestry-core/guide/rendering.html but still would be happy if you could answer to my first question. cheers kawes wrote: > > Olle, > > thanks a lot. I knew what was wrong but had no

Re: Layout Border component problem

2008-12-15 Thread kawes
Olle, thanks a lot. I knew what was wrong but had no idea how to deal with that. I am gonna check it out at home 'cause now I am at work. thanks again Olle Hallin wrote: > > What happens is that TeacherMode is mutable, and hence leaks state between > different users. You are *not* given a fr

Re: Layout Border component problem

2008-12-15 Thread Olle Hallin
What happens is that TeacherMode is mutable, and hence leaks state between different users. You are *not* given a fresh instance on each request. Instead, instances are pooled and reused. (Starting with 5.0.17, it is forbidden to have initial values on page member variables in order to prevent bu

RE: Layout Border component problem

2008-12-14 Thread kawes
Hi Jonathan, thanks for your quick response. As you asked I uploaded classes I hit the problem in. Small description: One of my sub-application is Teacher (should be able to provide a word in foreign language and accept user's answer checks wheather it is correct) When user logs in, clicks tea

RE: Layout Border component problem

2008-12-14 Thread Jonathan Barker
Tapestry pools pages and components, so it is supposed to re-use an available component rather than create a new one, if there is one available. It's a little like a server having a pool of worker threads to service requests. If you are having problem with the state being shared between users, the