The expected usage is now calling `NumLock.toggle(row, col, layer)` from within a macro. Signed-off-by: Gergely Nagy <algernon@madhouse-project.org>pull/365/head
parent
975cd0bf04
commit
051778048d
@ -1,17 +1,25 @@
|
|||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
#include "Keyboardio-LEDControl.h"
|
#include "Keyboardio-LEDControl.h"
|
||||||
|
#include "Keyboardio-Macros.h"
|
||||||
#include "LEDUtils.h"
|
#include "LEDUtils.h"
|
||||||
|
|
||||||
class LEDNumlock : LEDMode {
|
class NumLock_ : LEDMode {
|
||||||
public:
|
public:
|
||||||
LEDNumlock (uint8_t numpadIndex);
|
NumLock_ (void);
|
||||||
|
|
||||||
virtual void begin (void) final;
|
virtual void begin (void) final;
|
||||||
|
|
||||||
virtual void update (void) final;
|
virtual void update (void) final;
|
||||||
virtual void init (void) final;
|
virtual void init (void) final;
|
||||||
|
|
||||||
|
static const macro_t *toggle (byte row, byte col, uint8_t numPadLayer);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
static void loopHook (bool postClear);
|
static uint8_t previousLEDMode;
|
||||||
|
static uint8_t us;
|
||||||
|
static bool isActive;
|
||||||
|
static byte row, col;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
extern NumLock_ NumLock;
|
||||||
|
Loading…
Reference in new issue