UnityEditor.LazyTreeViewDataSource.IsChildListForACollapsedParent C# (CSharp) Method

IsChildListForACollapsedParent() public static method

public static IsChildListForACollapsedParent ( List childList ) : bool
childList List
return bool
        public static bool IsChildListForACollapsedParent(List<TreeViewItem> childList)
        {
            return (((childList != null) && (childList.Count == 1)) && (childList[0] == null));
        }

Usage Example

Exemplo n.º 1
0
 private static void SetChildren(TreeViewItem item, List <TreeViewItem> newChildList)
 {
     if (LazyTreeViewDataSource.IsChildListForACollapsedParent(item.children) && newChildList == null)
     {
         return;
     }
     item.children = newChildList;
 }