public void Destroy() { if (parent != null) parent.RemoveChild(this); parent = null; }
public virtual void RemoveChild(UIItem child) { children.Remove(child); }
public virtual void AddChild(UIItem child) { children.Add(child); child.defaults = defaults; child.parent = this; }