public virtual List<TreeViewItem> GetVisibleRows()
{
if ((this.m_VisibleRows == null) || this.m_NeedRefreshVisibleFolders)
{
if (this.m_RootItem != null)
{
if (this.m_TreeView.isSearching)
{
this.m_VisibleRows = this.Search(this.m_RootItem, this.m_TreeView.searchString.ToLower());
}
else
{
this.m_VisibleRows = this.ExpandedRows(this.m_RootItem);
}
}
else
{
Debug.LogError("TreeView root item is null. Ensure that your TreeViewDataSource sets up at least a root item.");
this.m_VisibleRows = new List<TreeViewItem>();
}
this.m_NeedRefreshVisibleFolders = false;
if (this.onVisibleRowsChanged != null)
{
this.onVisibleRowsChanged();
}
this.m_TreeView.Repaint();
}
return this.m_VisibleRows;
}