Saved the new state received from TellStick Duo

This commit is contained in:
Micke Prag 2009-02-09 11:25:44 +00:00
parent ca42ff2852
commit ccd80c5e70
2 changed files with 8 additions and 5 deletions

View file

@ -35,10 +35,8 @@ int Device::switchState( int newState, const std::string &value ) {
break;
}
if (retVal == TELLSTICK_SUCCESS) {
if (newState != TELLSTICK_BELL) { //Bell doesn't toggle any state
Manager *manager = Manager::getInstance();
manager->setDeviceState(deviceId, newState, "");
}
Manager *manager = Manager::getInstance();
manager->setDeviceState(deviceId, newState, "");
}
return retVal;
}