Call switchOn, if LEDs get enabled again

* Support devices which allow to be switched on/off physically,
rather than have a black output stream.
This commit is contained in:
LordGrey 2019-04-09 21:14:12 +02:00
parent 3661172d6d
commit c16ecde539
1 changed files with 6 additions and 0 deletions

View File

@ -52,6 +52,12 @@ void LedDevice::setEnable(bool enable)
{
switchOff();
}
else {
if ( !_enabled && enable)
{
switchOn();
}
}
_enabled = enable;
}