keybrd library is an open source library for creating custom-keyboard firmware.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
This repo is archived. You can view files and clone it, but cannot push or open issues/pull-requests.

Key_LayeredScSc.h 697B

12345678910111213141516171819202122
  1. #ifndef KEY_LAYEREDSCSC_H
  2. #define KEY_LAYEREDSCSC_H
  3. #include <Arduino.h>
  4. #include <inttypes.h>
  5. #include "LayerStateInterface.h"
  6. #include "Key_LayeredScScBase.h"
  7. /* Class Key_LayeredScSc is composed of two scancodes; "S" stands for Scancode.
  8. layerId is retreived from refLayerState.
  9. when layerId=0, press sends scancode0
  10. when layerId=1, press sends scancode1
  11. */
  12. class Key_LayeredScSc : public Key_LayeredScScBase
  13. {
  14. private:
  15. static LayerStateInterface& refLayerState;
  16. public:
  17. Key_LayeredScSc(const uint16_t scancode0, const uint16_t scancode1)
  18. : Key_LayeredScScBase(scancode0, scancode1) { }
  19. virtual void press();
  20. };
  21. #endif