i have written this code below to open a certain node "selectedXml" yet it
doesn't open it and it doesn't show the parents. instead, it just shows the
given node. Anyone knows what i should do?
private function clickedItem():void{
selectedXml = treeDP.selectedItem;
for each (var child:XML in parentXmlCopy.children()){
if
(child..model_chain.contains(selectedXml)||child.contains(selectedXml)||child.model_chain..task.contains(selectedXml)){
tree.expandChildrenOf(child,false);
len = selectedXml.childIndex();
trace(len);
expandConcernedNode(selectedXml);
}
}
}
private function expandConcernedNode(_xml:XML):void{
while (_xml.parent() != null) {
_xml = _xml.parent();
tree.expandItem(_xml, true, false);
tree.selectedItem = selectedXml;
}
}
I have searched alot on the internet, still no solution to the problem. I am
actually calling the clickedItem() function from a list Handler this way :
protected function treeDP_changeHandler(event:IndexChangeEvent):void
{
if(condRBT.selected||modelRBT.selected||taskRBT.selected||chainRBT.selected)
callLater(clickedItem);
}
--
You received this message because you are subscribed to the Google Groups "Flex
India Community" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/flex_india?hl=en.