public void RemoveControl(Control control) { control.Destroy(); if (ActiveControl == control) ActiveControl = null; Controls.Remove(control); }
public void AddControl(Control control, bool makeActive) { Controls.Add(control); control.setParent(this); if (makeActive) this.ActiveControl = control; //control.Location = new Vector2( // control.Location.X + location.X, // control.Location.Y + location.Y); }