public static ListViewItem ConstructItemAsMount(Directory dir) { var item = new ListViewItem(); item.Text = dir.Name + "(" + Mounts.IndexOf(dir).ToString() + ":/)"; item.Tag = Mounts.IndexOf(dir).ToString() + ":"; return(item); }
public void SetupTree() { tvfiles.Nodes.Clear(); foreach (var dir in Mounts) { var mountNode = new TreeNode(); mountNode.Text = dir.Name; mountNode.Tag = Mounts.IndexOf(dir).ToString() + ":"; RecursiveDirectoryAdd(mountNode); tvfiles.Nodes.Add(mountNode); } }