private void removeRootVisualisedDrawable() { if (targetDrawable != null) { treeContainer.Remove(targetDrawable); targetDrawable.Dispose(); targetDrawable = null; } }
private void removeRootVisualisedDrawable(bool hideProperties = true) { if (hideProperties) { propertyDisplay.State = Visibility.Hidden; } if (targetDrawable != null) { if (targetDrawable.Parent != null) { // targetDrawable may have gotten purged from the TreeContainer treeContainer.Remove(targetDrawable); targetDrawable.Dispose(); } targetDrawable = null; } }