public ProjectItem(EnvDTE.ProjectItem projectItem, IProjectItem parent = null) { Argument.IsNotNull("projectItem", projectItem); Initialize(projectItem.GetObjectName(), projectItem.IsFolder() ? ProjectItemType.Folder : ProjectItemType.File, parent); foreach (EnvDTE.ProjectItem subProjectItem in projectItem.ProjectItems) { ProjectItems.Add(new ProjectItem(subProjectItem, this)); } }