diff --git a/README.md b/README.md index b8173982..3bbe9948 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ -# Kaleidoscope-Numlock +# Kaleidoscope-NumPad -This is a plugin for [Kaleidoscope][fw], that adds a NumLock-specific LED +This is a plugin for [Kaleidoscope][fw], that adds a NumPad-specific LED effect, along with a way to toggle to a numpad layer, and apply the effect. [fw]: https://github.com/keyboardio/Kaleidoscope diff --git a/library.properties b/library.properties index 8db57a28..1155e73c 100644 --- a/library.properties +++ b/library.properties @@ -1,10 +1,10 @@ -name=Kaleidoscope-Numlock +name=Kaleidoscope-NumPad version=0.0.1 author=Jesse Vincent maintainer=Jesse Vincent -sentence=A Numlock plugin for Kaleidoscope. +sentence=A NumPad plugin for Kaleidoscope. paragraph=... category=Communication -url=https://github.com/keyboardio/Kaleidoscope-Numlock +url=https://github.com/keyboardio/Kaleidoscope-NumPad architectures=avr dot_a_linkage=true diff --git a/src/Kaleidoscope-Numlock.cpp b/src/Kaleidoscope-NumPad.cpp similarity index 79% rename from src/Kaleidoscope-Numlock.cpp rename to src/Kaleidoscope-NumPad.cpp index c7f2adf1..6ccb97fa 100644 --- a/src/Kaleidoscope-Numlock.cpp +++ b/src/Kaleidoscope-NumPad.cpp @@ -1,18 +1,18 @@ -#include "Kaleidoscope-Numlock.h" +#include "Kaleidoscope-NumPad.h" #include "LEDUtils.h" #include "Kaleidoscope.h" #include "layers.h" -byte NumLock_::row = 255, NumLock_::col = 255; -uint8_t NumLock_::numPadLayer; -bool NumLock_::cleanupDone = true; +byte NumPad_::row = 255, NumPad_::col = 255; +uint8_t NumPad_::numPadLayer; +bool NumPad_::cleanupDone = true; cRGB numpad_color = CRGB(255, 0, 0); -void NumLock_::begin(void) { +void NumPad_::begin(void) { Kaleidoscope.useLoopHook(loopHook); } -void NumLock_::loopHook(bool postClear) { +void NumPad_::loopHook(bool postClear) { if (!postClear) return; @@ -27,7 +27,7 @@ void NumLock_::loopHook(bool postClear) { cleanupDone = false; bool numState = !!(kaleidoscope::hid::getKeyboardLEDs() & LED_NUM_LOCK); if (!numState) { - kaleidoscope::hid::pressKey(Key_KeypadNumLock); + kaleidoscope::hid::pressKey(Key_KeypadNumPad); kaleidoscope::hid::sendKeyboardReport(); } @@ -58,4 +58,4 @@ void NumLock_::loopHook(bool postClear) { LEDControl.setCrgbAt(row, col, color); } -NumLock_ NumLock; +NumPad_ NumPad; diff --git a/src/Kaleidoscope-Numlock.h b/src/Kaleidoscope-NumPad.h similarity index 76% rename from src/Kaleidoscope-Numlock.h rename to src/Kaleidoscope-NumPad.h index bf33aa5e..3d60b417 100644 --- a/src/Kaleidoscope-Numlock.h +++ b/src/Kaleidoscope-NumPad.h @@ -4,9 +4,9 @@ #include "Kaleidoscope-Macros.h" #include "LEDUtils.h" -class NumLock_ : public KaleidoscopePlugin { +class NumPad_ : public KaleidoscopePlugin { public: - NumLock_(void) {} + NumPad_(void) {} void begin(void) final; @@ -19,4 +19,4 @@ class NumLock_ : public KaleidoscopePlugin { static bool cleanupDone; }; -extern NumLock_ NumLock; +extern NumPad_ NumPad;