Carsten, what toggle mode do you use? If it is clientside toggle, that this should be fixed with the nightly built.
Otherwise you can bind the whole component to your session bean or provide a TreeModel instead of a
TreeNode. It should work than like Sean explained it, because the state would be saved within the session-scoped TreeModel.
In addition, if you do not whant tree2 save the state between requests, as the TreeState is already session scoped, you can set the
transient property of the TreeState to true.

[EMAIL PROTECTED] schrieb am 22.08.2005 22:43:47:

> Am Sunday 21 August 2005 16:30 schrieb Sean Schofield:
> > I believe if you redirect to the same page you were on, you lose the
> > component tree.  I'm not sure about that though so maybe someone can
> > help clarify that point.  This would explain why your state stuff is
> > gone, b/c it is stored in the component by default.
> >
> > Take a look at the source for UITreeData.  In the new code you can now
> > provide your own TreeModel and TreeState class.  Instead of supplying
> > TreeNode like most of the simple examples, you can use TreeModel (like
> > the expandAll example.)  Just make the bean that provides your
> > TreeModel have session scope.  Or you could continue to provide
> > everything in one TreeNode and make the bean that supplies that
> > information session scope.  I haven't tested this lately so let me
> > know how it works out.
>
> I'm not sure if I understand you completely but I think this doesn'twork, at
> least here.
> I provide a TreeNode with a session scope bean and use it in a
> navigation that
> is included in all pages. When the user navigates from one page to another
> the state is lost and all nodes are collapsed when the next page is displayed
> the first time. Then he clicks somewhere on this page and the state of the
> nodes are restored.
> Nightly build from 08/14.
>
>
> Carsten

Reply via email to