예제 #1
0
 private void ClearChildern()
 {
     this.Childern = new ObservableCollection <DirectoryItemViewModel>();
     if (this.Type != DirectoryItemType.File)
     {
         Childern.Add(null);
     }
 }
예제 #2
0
 public void AddChild(bool setParent, params TreeNode[] nodes)
 {
     foreach (TreeNode node in nodes)
     {
         Childern.Add(node, node.Type);
         if (setParent)
         {
             node.Parent = this;
         }
     }
 }
예제 #3
0
        protected virtual void UpdateChildern()
        {
            Childern.Clear();

            for (int i = 0; i < transform.childCount; i++)
            {
                if (transform.GetChild(i).gameObject.activeInHierarchy&& !transform.GetChild(i).gameObject.GetComponent <LayoutSeperatorElement>())
                {
                    Childern.Add(transform.GetChild(i));
                }
            }
        }