public static void TraverseAllLeaves(UQtNode node, UQtForeachLeaf func) { if (node is UQtLeaf) { func(node as UQtLeaf); } else { foreach (var sub in node.SubNodes) { TraverseAllLeaves(sub, func); } } }
public static void TraverseAllLeaves(UQtNode node, UQtForeachLeaf func) { if (node is UQtLeaf) func(node as UQtLeaf); else foreach (var sub in node.SubNodes) TraverseAllLeaves(sub, func); }