public virtual void OnDetached(bool recursive) { /* detach children */ if (recursive && IsCompound) { foreach (DockObject child in Children) { child.Detach(recursive); } } /* detach the object itself */ flags &= ~(DockObjectFlags.Attached); DockObject parent = ParentObject; if (Parent != null && Parent is Container) { ((Container)Parent).Remove(this); } if (parent != null) { parent.Reduce(); } }
public virtual void OnDetached(bool recursive) { /* detach children */ if (recursive && IsCompound) { foreach (DockObject child in Children) { child.Detach (recursive); } } /* detach the object itself */ flags &= ~(DockObjectFlags.Attached); DockObject parent = ParentObject; if (Parent != null && Parent is Container) ((Container)Parent).Remove (this); if (parent != null) parent.Reduce (); }