diff options
Diffstat (limited to 'Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.HardwareDesigner/ViewModels/MainViewVM.cs')
| -rw-r--r-- | Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.HardwareDesigner/ViewModels/MainViewVM.cs | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.HardwareDesigner/ViewModels/MainViewVM.cs b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.HardwareDesigner/ViewModels/MainViewVM.cs index 73ba02435..918eb02d4 100644 --- a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.HardwareDesigner/ViewModels/MainViewVM.cs +++ b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.HardwareDesigner/ViewModels/MainViewVM.cs @@ -12,6 +12,8 @@ using Tango.BL; using Tango.SharedUI.Components; using System.Runtime.CompilerServices; using Tango.MachineStudio.Common; +using Tango.Core.ExtensionMethods; +using Tango.MachineStudio.HardwareDesigner.Views; namespace Tango.MachineStudio.HardwareDesigner.ViewModels { @@ -85,7 +87,7 @@ namespace Tango.MachineStudio.HardwareDesigner.ViewModels return name; } } - + private ObservableCollection<HardwareVersion> _hardwareVersions; public ObservableCollection<HardwareVersion> HardwareVersions { @@ -103,6 +105,8 @@ namespace Tango.MachineStudio.HardwareDesigner.ViewModels public RelayCommand CopyParametersCommand { get; set; } + public RelayCommand OpenComparisonWizardCommand { get; set; } + public MainViewVM(INotificationProvider notification) { _notification = notification; @@ -117,6 +121,8 @@ namespace Tango.MachineStudio.HardwareDesigner.ViewModels CopyParametersCommand = new RelayCommand(CopyParameters, (x) => SelectedVersion != null && IsFree); CloneCommand = new RelayCommand(CloneCurrentVersion, () => SelectedVersion != null && IsFree); + + OpenComparisonWizardCommand = new RelayCommand(OpenComparisonWizard); } public override void OnApplicationReady() @@ -427,6 +433,12 @@ namespace Tango.MachineStudio.HardwareDesigner.ViewModels } } + private void OpenComparisonWizard() + { + ComparisonWizardViewVM vm = new ComparisonWizardViewVM(HardwareVersions, SelectedVersion, _notification); + _notification.ShowModalDialog<ComparisonWizardViewVM, ComparisonWizardView>(vm, (x) => { }, () => { }); + } + protected override void RaisePropertyChangedAuto([CallerMemberName] string caller = null) { base.RaisePropertyChangedAuto(caller); |
