diff options
Diffstat (limited to 'Software/Visual_Studio/PPC/Tango.PPC.UI/PPCApplication/DefaultPPCApplicationManager.cs')
| -rw-r--r-- | Software/Visual_Studio/PPC/Tango.PPC.UI/PPCApplication/DefaultPPCApplicationManager.cs | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/Software/Visual_Studio/PPC/Tango.PPC.UI/PPCApplication/DefaultPPCApplicationManager.cs b/Software/Visual_Studio/PPC/Tango.PPC.UI/PPCApplication/DefaultPPCApplicationManager.cs index ef2b8aeee..7aeb6760e 100644 --- a/Software/Visual_Studio/PPC/Tango.PPC.UI/PPCApplication/DefaultPPCApplicationManager.cs +++ b/Software/Visual_Studio/PPC/Tango.PPC.UI/PPCApplication/DefaultPPCApplicationManager.cs @@ -182,7 +182,7 @@ namespace Tango.PPC.UI.PPCApplication //Start watchdog _watchdogServer = new WatchDogServer(Application.Current.Dispatcher); #if !DEBUG - + if (settings.EnableWatchDog) { _watchdogServer.Start(); @@ -425,6 +425,15 @@ namespace Tango.PPC.UI.PPCApplication } catch { } + try + { + if (_machineProvider.MachineOperator.State == Transport.TransportComponentState.Connected) + { + _machineProvider.MachineOperator.Adapter.Disconnect().Wait(); + } + } + catch { } + Process.Start(Application.ResourceAssembly.Location); Environment.Exit(0); } |
