Hi Sean,

thanks for the quick reply. I don't understand your answer :-(

My problem is that getNode() does not exist anymore in class TreeModelBase.

Eclipse claims that "The method getNode() is undefined for the type 
TreeModelBase" in the line
this.selectedNode = this._treeModel.getNode(); (see class abstract below)

Before the update of the tomahawk library everything worked fine :-(

When I dig in the source code repository of the tree2 implementation, I can 
see that TreeModelBase has no getNode() function.

old code worked fine before update:

public class MainScreenView {
        private TreeModelBase _treeModel = null;

        private TreeNode selectedNode;

        public TreeModel getTreeData() {
                // Create tree if TreeModel is null
                if (_treeModel == null) {
                        ... create tree
                }
                return _treeModel;
        }

        public String selectedNode() {
                this.selectedNode = this._treeModel.getNode();
                return ("main");
        }
}

    <t:tree2 id="serverTree" value="#{mainScreenView.treeData}" var="node" 
varNodeToggler="t" clientSideToggle="false">
        <f:facet name="location-folder">
            <h:panelGroup>
             <h:commandLink immediate="true" 
actionListener="#{t.setNodeSelected}" 
action="#{mainScreenView.selectedNode}">
            ... rendered elements removed
             </h:commandLink>
            </h:panelGroup>
        </f:facet>

regards

Dani

Reply via email to