From 64aeeb1d2784569e4ebf7c72c660458cf4432eee Mon Sep 17 00:00:00 2001 From: Victoria Plitt Date: Thu, 11 Apr 2019 11:24:39 +0300 Subject: Add menu to tree solution --- .../Dialogs/BaseProjectDialogVM.cs | 32 ++++++---------------- 1 file changed, 9 insertions(+), 23 deletions(-) (limited to 'Software/Visual_Studio/Scripting/Tango.Scripting.IDE/Dialogs/BaseProjectDialogVM.cs') diff --git a/Software/Visual_Studio/Scripting/Tango.Scripting.IDE/Dialogs/BaseProjectDialogVM.cs b/Software/Visual_Studio/Scripting/Tango.Scripting.IDE/Dialogs/BaseProjectDialogVM.cs index 7742a3434..631aaaed3 100644 --- a/Software/Visual_Studio/Scripting/Tango.Scripting.IDE/Dialogs/BaseProjectDialogVM.cs +++ b/Software/Visual_Studio/Scripting/Tango.Scripting.IDE/Dialogs/BaseProjectDialogVM.cs @@ -61,39 +61,25 @@ namespace Tango.Scripting.IDE.Dialogs get { return _projectLocation; } set { _projectLocation = value; RaisePropertyChangedAuto(); InvalidateRelayCommands(); } } - + public String GetFullProjectPath() + { + StringBuilder builder = new StringBuilder(ProjectLocation); + builder.AppendFormat(@"{0}\{1}", ProjectLocation, ProjectName); + return builder.ToString(); + } #endregion #region constructor - public BaseProjectDialogVM() : base() + public BaseProjectDialogVM(List project_types) : base() { ProjectTypes = new ObservableCollection(); - RegisterProjectType(new StubProjectType()); - RegisterProjectType(new UnitTestProjectType()); - + project_types.ForEach(ProjectTypes.Add); _selectedProjectType = ProjectTypes.FirstOrDefault(); - - string workingDirectory = Environment.CurrentDirectory; - ProjectLocation = Directory.GetParent(workingDirectory).Parent.Parent.FullName; } #endregion - - #region register_project_types - - public void RegisterProjectType(IProjectType projectType) - { - ProjectTypes.Add(projectType); - } - - public void UnRegisterProjectItemHandler(IProjectType projectType) - { - ProjectTypes.Remove(projectType); - } - - #endregion - + #region Override Methods protected override bool CanOK() -- cgit v1.3.1