It would be nice if LED effects could be activated via their object, not just their number, so that one could write - say, in a macro - `myEffect.activate()`, and have it become the active mode. To implement this, `LEDControl_` gains an `activate` method, that takes a pointer, finds it in the mode array, and switches to its index (if found). `LEDMode` gains an `activate` method too, which uses `LEDControl`s new method of the same name to activate itself. Signed-off-by: Gergely Nagy <algernon@madhouse-project.org>pull/48/head
parent
4fc567cea5
commit
37f5d1d1b8
Loading…
Reference in new issue