Beispiel #1
0
        public void SetSolutionItemEnabled(string solutionItemPath, bool enabled)
        {
            solutionItemPath = GetRelativeChildPath(Path.GetFullPath(solutionItemPath));
            var list = UserProperties.GetValue <List <string> > ("DisabledProjects");

            if (!enabled)
            {
                if (list == null)
                {
                    list = new List <string> ();
                }
                if (!list.Contains(solutionItemPath))
                {
                    list.Add(solutionItemPath);
                }
                UserProperties.SetValue("DisabledProjects", list);
            }
            else if (list != null)
            {
                list.Remove(solutionItemPath);
                if (list.Count == 0)
                {
                    UserProperties.RemoveValue("DisabledProjects");
                }
                else
                {
                    UserProperties.SetValue("DisabledProjects", list);
                }
            }
        }
Beispiel #2
0
        public override void SaveUserProperties()
        {
            UserProperties.SetValue("StartupItem", (string)GetRelativeChildPath(StartupItemFileName));
            if (MultiStartupItemFileNames != null)
            {
                UserProperties.SetValue("StartupItems", MultiStartupItemFileNames.Select(p => (string)GetRelativeChildPath(p)).ToArray());
            }
            else
            {
                UserProperties.RemoveValue("StartupItems");
            }

            CollectItemProperties(UserProperties, RootFolder, "MonoDevelop.Ide.ItemProperties");
            base.SaveUserProperties();
            CleanItemProperties(UserProperties, RootFolder, "MonoDevelop.Ide.ItemProperties");
        }