using System; using System.Collections.Generic; namespace org.budnhead { public class Container : Control { private List children; public Container() { this.children = new List(); } public void addChild(Control control){ if (control.parent != null){ control.parent.removeChild(control); } this.children.Add(control); } public void removeChild(Control control){ this.children.Remove(control); } public Control[] Children { get { return this.children.ToArray(); } } } }