public void RemoveChild(int index) { BaseControl ctrl = this.children[index]; ctrl.OnDestroy(); this.children.RemoveAt(index); }
public void RemoveChild(BaseControl ctrl) { ctrl.OnDestroy(); this.children.Remove(ctrl); }