From 19bc5f7845b4dd400395cd9f8fd5134cf6e8b3ea Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Simon=20St=C3=BCrz?= Date: Tue, 19 Jan 2016 11:28:46 +0100 Subject: [PATCH] remove test actions --- .../awattar/devicepluginawattar.cpp | 27 ++++++++-------- .../awattar/devicepluginawattar.json | 31 ------------------- 2 files changed, 14 insertions(+), 44 deletions(-) diff --git a/plugins/deviceplugins/awattar/devicepluginawattar.cpp b/plugins/deviceplugins/awattar/devicepluginawattar.cpp index 39c7a8d2..17b1c63f 100644 --- a/plugins/deviceplugins/awattar/devicepluginawattar.cpp +++ b/plugins/deviceplugins/awattar/devicepluginawattar.cpp @@ -217,22 +217,23 @@ void DevicePluginAwattar::guhTimer() DeviceManager::DeviceError DevicePluginAwattar::executeAction(Device *device, const Action &action) { Q_UNUSED(device) + Q_UNUSED(action) - if (action.actionTypeId() == ledPowerActionTypeId) { - foreach (HeatPump *pump, m_heatPumps) { - if (!pump->reachable()) - return DeviceManager::DeviceErrorHardwareNotAvailable; +// if (action.actionTypeId() == ledPowerActionTypeId) { +// foreach (HeatPump *pump, m_heatPumps) { +// if (!pump->reachable()) +// return DeviceManager::DeviceErrorHardwareNotAvailable; - pump->setLed(action.param("led power").value().toBool()); - } - } else if (action.actionTypeId() == sgModeActionTypeId) { - foreach (HeatPump *pump, m_heatPumps) { - if (!pump->reachable()) - return DeviceManager::DeviceErrorHardwareNotAvailable; +// pump->setLed(action.param("led power").value().toBool()); +// } +// } else if (action.actionTypeId() == sgModeActionTypeId) { +// foreach (HeatPump *pump, m_heatPumps) { +// if (!pump->reachable()) +// return DeviceManager::DeviceErrorHardwareNotAvailable; - pump->setSgMode(action.param("sg-mode").value().toInt()); - } - } +// pump->setSgMode(action.param("sg-mode").value().toInt()); +// } +// } return DeviceManager::DeviceErrorNoError; } diff --git a/plugins/deviceplugins/awattar/devicepluginawattar.json b/plugins/deviceplugins/awattar/devicepluginawattar.json index a7f7536f..28775a3a 100644 --- a/plugins/deviceplugins/awattar/devicepluginawattar.json +++ b/plugins/deviceplugins/awattar/devicepluginawattar.json @@ -114,37 +114,6 @@ ], "defaultValue": "0 - Invalid" } - ], - "actionTypes": [ - { - "id": "5be2f57f-a22d-4766-856a-a31481bcf6d6", - "idName": "ledPower", - "name": "set led power", - "paramTypes": [ - { - "name": "power", - "type": "bool" - } - ] - }, - { - "id": "03af6639-a815-4291-abbb-26fc81cdf740", - "idName": "sgMode", - "name": "set sg-mode", - "paramTypes": [ - { - "name": "sg-mode", - "type": "QString", - "defaultValue": "1", - "allowedValues": [ - "1", - "2", - "3", - "4" - ] - } - ] - } ] } ]