OneShot has a convenient way to tell us if any OneShot keys are active:
`OneShot.isActive()`. Thus, if we are using oneshots only, we can skip scanning
the whole keymap if no one-shots are active, saving us a whole lot of time per
cycle we would be spending needlessly.
The optimization is off by default, and must be turned on by the user's sketch.
Signed-off-by: Gergely Nagy <kaleidoscope@gergo.csillger.hu>
Instead of using `Kaleidoscope-Ranges` and custom helper functions with magic
constants to decide whether we need to highlight a key, refresh it, or leave it
alone, use an if-else chain and inner ifs for activity.
Leverages the new `OneShot.isOneShotKey(key)` and `OneShot.isActive(key)`
methods.
The net result is slightly cleaner code (though it can still be improved), and
about 0.2ms saved, along with some PROGMEM space.
Signed-off-by: Gergely Nagy <kaleidoscope@gergo.csillger.hu>
Make it clear that layer keys are considered modifiers by the plugin.
While in that area, use `Kaleidoscope.use` instead of the now deprecated
`USE_PLUGINS` macro.
Signed-off-by: Gergely Nagy <algernon@madhouse-project.org>
Renamed the library to Kaleidoscope-LED-ActiveModColor, and followed up with
other renames.
Signed-off-by: Gergely Nagy <algernon@madhouse-project.org>