Update LinearColorSmoothing.cpp

disable smooth timer when disabled
This commit is contained in:
redPanther 2016-09-08 18:07:57 +02:00 committed by GitHub
parent 36124c9afb
commit 951aab1c9d
1 changed files with 6 additions and 0 deletions

View File

@ -136,6 +136,12 @@ void LinearColorSmoothing::queueColors(const std::vector<ColorRgb> & ledColors)
void LinearColorSmoothing::setEnable(bool enable)
{
_enabled = enable;
if (!enable)
{
_timer.stop();
_previousValues.clear();
}
}
bool LinearColorSmoothing::enabled()