[
https://issues.apache.org/jira/browse/TRINIDAD-2356?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
hongbing wang updated TRINIDAD-2356:
------------------------------------
Status: Patch Available (was: Open)
> Regression caused by the check in of issue TRINIDAD-2158
> --------------------------------------------------------
>
> Key: TRINIDAD-2356
> URL: https://issues.apache.org/jira/browse/TRINIDAD-2356
> Project: MyFaces Trinidad
> Issue Type: Bug
> Components: Components
> Affects Versions: 2.0.1-core
> Reporter: hongbing wang
>
> The fix of issue TRINIDAD-2158 causes a regression in tree when
> initiallyExpanded is used. The iterator of disclosed row key set doesn't
> return next correctly, which cause the tree can not render all initially
> expanded nodes.
> The following fix in RowKeySetTreeNode
> // When the currentNode has no child nodes, the
> // iterator instance is not pushed to iteratorStack.
> if(!nextNode.getValue().isEmpty())
> {
> _iteratorStack.push(_currIterator);
> _currIterator = nextNode.getValue().entrySet().iterator();
> if(nextNode.getValue().isDefaultContained)
> {
> _currPath = nextNode.getKey();
> TreeModel model = getCollectionModel();
> Object oldPath = model.getRowKey();
> model.setRowKey(_currPath);
> _minDepth = model.getDepth() + 1;
> model.setRowKey(oldPath);
> return nextKey;
> }
> }
> should be changed to let the tree node to set _currPath and _miniDepth
> correctly.
> // When the currentNode has no child nodes, the
> // iterator instance is not pushed to iteratorStack.
> if(!nextNode.getValue().isEmpty())
> {
> _iteratorStack.push(_currIterator);
> _currIterator = nextNode.getValue().entrySet().iterator();
> }
> if(nextNode.getValue().isDefaultContained)
> {
> _currPath = nextNode.getKey();
> TreeModel model = getCollectionModel();
> Object oldPath = model.getRowKey();
> model.setRowKey(_currPath);
> _minDepth = model.getDepth() + 1;
> model.setRowKey(oldPath);
> return nextKey;
> }
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira