示例#1
0
 private void _RemoveChild(GLModel3D model)
 {
     if (model.Parent != this)
     {
         throw new InvalidOperationException("The logical parent is error");
     }
     _children.Remove(model);
     model.Parent = null;
 }
示例#2
0
 private void _AddChild(GLModel3D model)
 {
     if (model.Parent != null)
     {
         throw new InvalidOperationException("The model has a logical parent");
     }
     if (model.Visual != null)
     {
         throw new InvalidOperationException("The model has associated visual");
     }
     _children.Add(model);
     model.Parent = this;
 }
示例#3
0
 public void RemoveChild(GLModel3D model)
 {
     _RemoveChild(model);
     _OnChildrenChanged();
 }
示例#4
0
 public void AddChild(GLModel3D model)
 {
     _AddChild(model);
     _OnChildrenChanged();
 }