Inheritance: INotifyPropertyChanged
Beispiel #1
0
        public static bool IsSyncTemplate(this ProjectItemInfo item)
        {
            if (item.IsFolder)
            {
                return(((ProjectFolderInfo)item).IsSyncTemplate());
            }

            if (item.IsFile)
            {
                return(((ProjectFileInfo)item).IsSyncTemplate());
            }

            return(false);
        }
Beispiel #2
0
        public static bool IsChecked(this ProjectItemInfo item)
        {
            if (item.IsFolder)
            {
                return(((ProjectFolderInfo)item).IsChecked());
            }

            if (item.IsFile)
            {
                return(((ProjectFileInfo)item).IsChecked());
            }

            return(false);
        }
Beispiel #3
0
        public static ProjectFolderInfo GetTopFolder(this ProjectItemInfo item)
        {
            if (item == null)
            {
                return(null);
            }

            ProjectFolderInfo parent = item.Parent;

            if ((parent == null || String.IsNullOrEmpty(parent.Path) || parent.ProjectFolderRole == Misc.ProjectFolderRole.Other) && item.IsFolder)
            {
                return(item as ProjectFolderInfo);
            }

            return(GetTopFolder(parent));
        }