X-Git-Url: https://git.piment-noir.org/?a=blobdiff_plain;f=src%2Fcec-config-gui%2Factions%2FConnectToDevice.cs;h=8c198f4c60a20f86042aada349c0c0618ca81118;hb=75060af4927b7e412634756bb1ec952a25fab772;hp=fedc31398e700c7721b9bb89f7f91ec77f51424a;hpb=f916b582a00b685f0c6b29f8567f703492af2f76;p=deb_libcec.git diff --git a/src/cec-config-gui/actions/ConnectToDevice.cs b/src/cec-config-gui/actions/ConnectToDevice.cs index fedc313..8c198f4 100644 --- a/src/cec-config-gui/actions/ConnectToDevice.cs +++ b/src/cec-config-gui/actions/ConnectToDevice.cs @@ -22,7 +22,10 @@ namespace CecConfigGui.actions { DialogResult result = MessageBox.Show("Could not detect to any CEC adapter. Please check your configuration. Do you want to try again?", "Pulse-Eight USB-CEC Adapter", MessageBoxButtons.YesNo); if (result == DialogResult.No) - Application.Exit(); + { + SendEvent(UpdateEventType.ExitApplication); + return; + } else adapters = Lib.FindAdapters(string.Empty); } @@ -31,7 +34,10 @@ namespace CecConfigGui.actions { DialogResult result = MessageBox.Show("Could not connect to any CEC adapter. Please check your configuration. Do you want to try again?", "Pulse-Eight USB-CEC Adapter", MessageBoxButtons.YesNo); if (result == DialogResult.No) - Application.Exit(); + { + SendEvent(UpdateEventType.ExitApplication); + return; + } } SendEvent(UpdateEventType.ProgressBar, 20);