private Boolean RemoveElement(List <RICustomDataElement> children, RICustomDataElement element) { foreach (RICustomDataElement elm in children) { if (Object.ReferenceEquals(elm, element)) { Children.Remove(elm); return(true); } else if (elm.CustomDataType == RICustomDataElementType.Category || elm.CustomDataType == RICustomDataElementType.Container) { if (RemoveElement((elm as RICustomDataCategory).Children, element)) { return(true); } } } return(false); }
public Boolean RemoveElement(RICustomDataElement element) { return(RemoveElement(Children, element)); }