Hi Chris,
I have the same problem, and i found a solution to pass over. i delete my myfaces tree : name "tree1", in the jsf tree component, and its works now fine.

// delete component "tree1" directly in the jsf tree component if(FacesContext.getCurrentInstance().getViewRoot().findComponent("tree1") != null){ List listTmp = FacesContext.getCurrentInstance().getViewRoot().findComponent("tree1").getParent().getChildren(); if(listTmp!=null) listTmp.remove(FacesContext.getCurrentInstance().getViewRoot().findComponent("tree1"));
               }
treeData1 = ..... // load data
               treeModel1 = new TreeModelBase(treeData1); // load model
treeHtml1 = new HtmlTree(); // create new instance for binding


   <t:tree2 id="tree1"
           value="#{TreeBean.treeModel1}"
           binding="#{TreeBean.treeHtml1}"
           var="node"
           varNodeToggler="t"
           clientSideToggle="true"
           preserveToggle="false">

   </tree2>


Adrien



Sean Schofield wrote:

I think this is the issue:

http://issues.apache.org/jira/browse/TOMAHAWK-437

Its on my list of tree2 issues to address.  Right now we're sorting
through some big picture tomahawk and core issues.

Sean


On 5/23/06, Chris Hane <[EMAIL PROTECTED]> wrote:

This isn't going to help too much; but I started to run into the same
things when I was using tree2 and client side expand/collapse.

What I tracked it down to was the expand/collapse state is stored in a
cookie that is relevant for a the tree2 component on a specific screen.
For me that meant when I had to the same screen open in two windows
(different records though), they "shared" the expand/collapse state.
This causes weird looking behavior (e.g., expand three node in one
screen, go to the second screen and expand a node and three are expanded
(the same three from the first screen)).

At the time I wasn't setup to explore the tomahawk code so I found a
work around for my specific case (I expand all nodes all the time and
don't let the user collapse). I opened a JIRA on this issue - the
archives have the specific #.

Having said that, I'm not an expert with tomahawk - actually just
starting so I might be doing something wrong...

Chris....

Christopher J. Bowerman wrote:
>
> Hi,
>
> I'm using a tree2 component. My problem seems to have to do with tree
> state. The tree works fine the first time I render it, but I have a
> "home" button that starts the user input over again and builds a new
> tree. When the new tree is rendered the nodes that were expanded in
> the earlier tree are expanded in this one as well. I'd like the tree
> to be fully collapsed whenever I've built a new tree. Can anybody
> actually tell me how I can do this? I've seen other mention of it on
> previous posts, but they were almost a year ago and no mention how to
> actually go about it. Any help would be greatly appreciated.
>
> Thanks.
>
> ==================================
>
> Christopher J. Bowerman
>
> Internet Applications Developer
>
> SAIC-Frederick
>
> phone: 301.846.5275
>
> email: [EMAIL PROTECTED]
> <mailto:[EMAIL PROTECTED]>
>
> ------------------------------------------------------------------------
>
> No virus found in this incoming message.
> Checked by AVG Free Edition.
> Version: 7.1.392 / Virus Database: 268.7.0/345 - Release Date: 5/22/2006
>


--
No virus found in this outgoing message.
Checked by AVG Free Edition.
Version: 7.1.392 / Virus Database: 268.7.0/345 - Release Date: 5/22/2006




Reply via email to