From 00a491d93733d4625ad329b2ba8237f445364b3f Mon Sep 17 00:00:00 2001 From: Mirta Date: Wed, 30 Dec 2020 16:39:52 +0200 Subject: merge --- .../DefaultStudioApplicationManager.cs | 35 +++++----------------- 1 file changed, 8 insertions(+), 27 deletions(-) (limited to 'Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UI/StudioApplication/DefaultStudioApplicationManager.cs') diff --git a/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UI/StudioApplication/DefaultStudioApplicationManager.cs b/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UI/StudioApplication/DefaultStudioApplicationManager.cs index feed9e193..0235f8cca 100644 --- a/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UI/StudioApplication/DefaultStudioApplicationManager.cs +++ b/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UI/StudioApplication/DefaultStudioApplicationManager.cs @@ -42,18 +42,12 @@ namespace Tango.MachineStudio.UI.StudioApplication private INotificationProvider _notification; private List _openedWindows; private List _notified_view_models; - private bool _isDialogShown; /// /// Occurs when the application is ready. /// public event EventHandler ApplicationReady; - /// - /// Occurs when the connected machine session has been lost and an automatic reconnection with the last machine is required. - /// - public event EventHandler ReconnectionRequired; - /// /// Initializes a new instance of the class. /// @@ -138,28 +132,15 @@ namespace Tango.MachineStudio.UI.StudioApplication { String failed_reason = (sender as IMachineOperator).FailedStateException.Message; - if (!_isDialogShown) + ConnectionLostViewVM vm = new ConnectionLostViewVM() { - _isDialogShown = true; + Exception = failed_reason + }; - ConnectionLostViewVM vm = new ConnectionLostViewVM() - { - Exception = failed_reason, - AutoReconnect = true, - }; - - InvokeUI(() => - { - _notification.ShowModalDialog(vm, (x) => - { - _isDialogShown = false; - ReconnectionRequired?.Invoke(this, new EventArgs()); - }, () => - { - _isDialogShown = false; - }); - }); - } + InvokeUI(() => + { + _notification.ShowModalDialog(vm, (x) => { }, () => { }); + }); } } } @@ -291,7 +272,7 @@ namespace Tango.MachineStudio.UI.StudioApplication var eventLogger = TangoIOC.Default.GetInstance(); if (eventLogger != null) { - //eventLogger.Log(EventTypes.APPLICATION_TERMINATED, "Application Terminated!"); + eventLogger.Log(EventTypes.APPLICATION_TERMINATED, "Application Terminated!"); eventLogger.FlushAll(); } -- cgit v1.3.1