From 3fdcdac577d552bbdf6d7320c6ffb0753e810a08 Mon Sep 17 00:00:00 2001 From: Roy Ben-Shabat Date: Sun, 10 Dec 2017 19:01:05 +0200 Subject: Started working on machine designer view models. Added NAME field to MACHINE table. --- .../Utilities/Tango.MachineDesigner.UI/ViewModelLocator.cs | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) (limited to 'Software/Visual_Studio/Utilities/Tango.MachineDesigner.UI/ViewModelLocator.cs') diff --git a/Software/Visual_Studio/Utilities/Tango.MachineDesigner.UI/ViewModelLocator.cs b/Software/Visual_Studio/Utilities/Tango.MachineDesigner.UI/ViewModelLocator.cs index 6b8bc5aea..5d26a3e21 100644 --- a/Software/Visual_Studio/Utilities/Tango.MachineDesigner.UI/ViewModelLocator.cs +++ b/Software/Visual_Studio/Utilities/Tango.MachineDesigner.UI/ViewModelLocator.cs @@ -33,17 +33,14 @@ namespace Tango.MachineDesigner.UI //// SimpleIoc.Default.Register(); ////} - LogManager.Log("Registering MainView View Model..."); SimpleIoc.Default.Register(); + SimpleIoc.Default.Register(); //Register View (Supervising Controller Pattern). if (!ViewModelBase.IsInDesignModeStatic) { LogManager.Log(String.Format("Registering Supervising Controller {0}...", nameof(IMainView))); SimpleIoc.Default.Register(() => (IMainView)MainView.Self); - - LogManager.Log(String.Format("Registering Supervising Controller {0}...", nameof(IMachinesView))); - SimpleIoc.Default.Register(() => (IMachinesView)MainView.Self); } } @@ -54,5 +51,13 @@ namespace Tango.MachineDesigner.UI return ServiceLocator.Current.GetInstance(); } } + + public MachinesViewVM MachinesViewVM + { + get + { + return ServiceLocator.Current.GetInstance(); + } + } } } \ No newline at end of file -- cgit v1.3.1