From fe589d0e841bf3a6d7c3206a7e48c8e7ae9a91a8 Mon Sep 17 00:00:00 2001 From: Roy Ben-Shabat Date: Tue, 28 Aug 2018 18:33:42 +0300 Subject: Some work. --- .../PPC/Tango.PPC.UI/ViewModels/MachineSetupViewVM.cs | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) (limited to 'Software/Visual_Studio/PPC/Tango.PPC.UI/ViewModels/MachineSetupViewVM.cs') diff --git a/Software/Visual_Studio/PPC/Tango.PPC.UI/ViewModels/MachineSetupViewVM.cs b/Software/Visual_Studio/PPC/Tango.PPC.UI/ViewModels/MachineSetupViewVM.cs index 57c2200c6..ef033626a 100644 --- a/Software/Visual_Studio/PPC/Tango.PPC.UI/ViewModels/MachineSetupViewVM.cs +++ b/Software/Visual_Studio/PPC/Tango.PPC.UI/ViewModels/MachineSetupViewVM.cs @@ -171,15 +171,6 @@ namespace Tango.PPC.UI.ViewModels SkipEmbeddedTestCommand = new RelayCommand(SkipEmbeddedTest); InstallCommand = new RelayCommand(Install); RestartCommand = new RelayCommand(() => { NavigateTo(MachineSetupView.WelcomeView); }); - - if (!LogManager.Categories.Contains(LogCategory.Debug)) - { - LogManager.Categories.Add(LogCategory.Debug); - } - - var logger = new SimpleStringLogger(); - LogManager.RegisterLogger(logger); - logger.LogReceived += Logger_LogReceived; } #endregion @@ -193,6 +184,15 @@ namespace Tango.PPC.UI.ViewModels /// The instance containing the event data. private void ApplicationManager_SetupRequired(object sender, EventArgs e) { + if (!LogManager.Categories.Contains(LogCategory.Debug)) + { + LogManager.Categories.Add(LogCategory.Debug); + } + + var logger = new SimpleStringLogger(); + LogManager.RegisterLogger(logger); + logger.LogReceived += Logger_LogReceived; + LogManager.Log("SetupRequired event received. Navigating to MachineSetupView..."); NavigationManager.NavigateTo(NavigationView.MachineSetupView); } -- cgit v1.3.1