| | |
| | | |
| | | private Dictionary<string, object> dumpHierarchyImpl (AbstractNode node, bool onlyVisibleNode) |
| | | { |
| | | if (node == null) { |
| | | if (node == null) |
| | | { |
| | | return null; |
| | | } |
| | | |
| | |
| | | result.Add ("payload", payload); |
| | | |
| | | List<object> children = new List<object> (); |
| | | foreach (AbstractNode child in node.getChildren()) { |
| | | if (!onlyVisibleNode || (bool)child.getAttr ("visible")) { |
| | | foreach (AbstractNode child in node.getChildren()) |
| | | { |
| | | if (!onlyVisibleNode || (bool)child.getAttr("visible")) |
| | | { |
| | | children.Add (dumpHierarchyImpl (child, onlyVisibleNode)); |
| | | } |
| | | } |
| | | if (children.Count > 0) { |
| | | if (children.Count > 0) |
| | | { |
| | | result.Add ("children", children); |
| | | } |
| | | return result; |