Esempio n. 1
0
 public FolderIncludeTreeViewItem_Root(IReadOnlyCollection <IncludeGraph.GraphItem> graphItems, IncludeGraph.GraphItem includingFile)
 {
     this.graphItems       = graphItems;
     this.includingFile    = includingFile;
     this.Name             = "Root";
     this.AbsoluteFilename = "Root";
 }
Esempio n. 2
0
 public void Reset(IReadOnlyCollection <IncludeGraph.GraphItem> graphItems, IncludeGraph.GraphItem includingFile)
 {
     this.graphItems    = graphItems;
     this.includingFile = includingFile;
     this.cachedItems   = null;
     NotifyAllPropertiesChanged();
 }
Esempio n. 3
0
        public FolderIncludeTreeViewItem_Leaf(IncludeGraph.GraphItem item)
        {
            try
            {
                Name = Path.GetFileName(item.AbsoluteFilename);
            }
            catch
            {
                Name = item?.FormattedName;
            }
            AbsoluteFilename = item?.AbsoluteFilename;

            if (string.IsNullOrWhiteSpace(AbsoluteFilename) || !Path.IsPathRooted(AbsoluteFilename))
            {
                ParentFolder = FolderIncludeTreeViewItem_Folder.UnresolvedFolderName;
            }
            else
            {
                ParentFolder = Path.GetDirectoryName(AbsoluteFilename);
            }
        }