[apps] Create a LED timer

Change-Id: Ice5a5fbf9fdf7b493597aa9542206372ebf0ae81
This commit is contained in:
Émilie Feral
2017-04-07 11:39:16 +02:00
parent dadeb98d99
commit 1bf44a3fb0
3 changed files with 29 additions and 0 deletions

13
apps/led_timer.cpp Normal file
View File

@@ -0,0 +1,13 @@
#include "led_timer.h"
LedTimer::LedTimer() :
Timer(1),
m_on(false)
{
}
void LedTimer::fire() {
m_on = !m_on;
KDColor ledColor = m_on ? KDColorRed : KDColorBlack;
Ion::LED::setColor(ledColor);
}