X-Git-Url: https://git.piment-noir.org/?a=blobdiff_plain;f=src%2FLibCecTray%2Fcontroller%2FCECController.cs;h=c394c08f336bd7e1f099fda73d76eb50df7a6263;hb=caa97b09d05e298788be1d0d8d50608a70c9757b;hp=94fac2e4349e0bc4c76ecb83aab13f2ac6f8232e;hpb=5b431288fe91e15ddb6d0757354ce78d6ce450e8;p=deb_libcec.git diff --git a/src/LibCecTray/controller/CECController.cs b/src/LibCecTray/controller/CECController.cs index 94fac2e..c394c08 100644 --- a/src/LibCecTray/controller/CECController.cs +++ b/src/LibCecTray/controller/CECController.cs @@ -367,6 +367,32 @@ namespace LibCECTray.controller return 1; } + public override int ReceiveAlert(CecAlert alert, CecParameter data) + { + switch (alert) + { + case CecAlert.ServiceDevice: + MessageBox.Show(Resources.alert_service_device, Resources.cec_alert, MessageBoxButtons.OK); + break; + case CecAlert.ConnectionLost: + MessageBox.Show(Resources.alert_connection_lost, Resources.cec_alert, MessageBoxButtons.OK); + break; + case CecAlert.PermissionError: + MessageBox.Show(Resources.alert_permission_error, Resources.cec_alert, MessageBoxButtons.OK); + break; + case CecAlert.PortBusy: + MessageBox.Show(Resources.alert_port_busy, Resources.cec_alert, MessageBoxButtons.OK); + break; + case CecAlert.PhysicalAddressError: + MessageBox.Show(Resources.alert_physical_address_error, Resources.cec_alert, MessageBoxButtons.OK); + break; + case CecAlert.TVPollFailed: + MessageBox.Show(Resources.alert_tv_poll_failed, Resources.cec_alert, MessageBoxButtons.OK); + break; + } + return 1; + } + public override int ConfigurationChanged(LibCECConfiguration config) { Settings.PhysicalAddress.Value = Config.PhysicalAddress;