numberOfVisibleDescendants method
Collapsing and expanding - end
Implementation
int numberOfVisibleDescendants() {
if (this.treeNode.expanded) {
int sum = this.childControllers.length;
this.childControllers.forEach((item) {
sum += item.numberOfVisibleDescendants();
});
_numberOfVisibleChildren = sum;
} else {
return 0;
}
return _numberOfVisibleChildren;
}