diff options
Diffstat (limited to 'quantum/template/keymaps/default/keymap.c')
| -rw-r--r-- | quantum/template/keymaps/default/keymap.c | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/quantum/template/keymaps/default/keymap.c b/quantum/template/keymaps/default/keymap.c new file mode 100644 index 000000000..4121fd860 --- /dev/null +++ b/quantum/template/keymaps/default/keymap.c | |||
| @@ -0,0 +1,30 @@ | |||
| 1 | // This is the canonical layout file for the Quantum project. If you want to add another keyboard, | ||
| 2 | // this is the style you want to emulate. | ||
| 3 | |||
| 4 | #include "%KEYBOARD%.h" | ||
| 5 | |||
| 6 | const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { | ||
| 7 | [0] = KEYMAP( /* Base */ | ||
| 8 | KC_A, KC_1, KC_H, \ | ||
| 9 | KC_TAB, KC_SPC \ | ||
| 10 | ), | ||
| 11 | }; | ||
| 12 | |||
| 13 | const uint16_t PROGMEM fn_actions[] = { | ||
| 14 | |||
| 15 | }; | ||
| 16 | |||
| 17 | const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt) | ||
| 18 | { | ||
| 19 | // MACRODOWN only works in this function | ||
| 20 | switch(id) { | ||
| 21 | case 0: | ||
| 22 | if (record->event.pressed) { | ||
| 23 | register_code(KC_RSFT); | ||
| 24 | } else { | ||
| 25 | unregister_code(KC_RSFT); | ||
| 26 | } | ||
| 27 | break; | ||
| 28 | } | ||
| 29 | return MACRO_NONE; | ||
| 30 | }; | ||
