是否FrameWorkElement.RemoveFromVisualTree()
删除父级的所有子控件或将它们设置为空?
例如有没有区别
var s = (LayoutGroup)sender;
foreach (var child in s.Children)
{
child = null;
}
s.RemoveFromVisualTree();
和
var s = (LayoutGroup)sender;
s.RemoveFromVisualTree();