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.

287 lines
8.0 KiB

[Keymap] merge jdelkins userspace and associated keymaps (#11276) * [Keymap] merge jdelkins userspace and associated keymaps * Add copyright & license info * Change rgblight_config.enable to rgblight_is_enabled() * Update keyboards/dz60/keymaps/jdelkins/keymap.c Co-authored-by: Drashna Jaelre <drashna@live.com> * Update keyboards/dz60/keymaps/jdelkins/keymap.c Co-authored-by: Drashna Jaelre <drashna@live.com> * Update keyboards/dz60/keymaps/jdelkins/keymap.c Co-authored-by: Drashna Jaelre <drashna@live.com> * Remove superfluous includes * Change EXTRAFLAGS+=-flto to LTO_ENABLE=yes * Remove unnecessary jdelkins_ss symlink in users * Add copyright and license notices * Use preferred way to determine capslock / numlock state Co-authored-by: Drashna Jaelre <drashna@live.com> * Add #pragma once to a header Co-authored-by: Drashna Jaelre <drashna@live.com> * Include QMK_KEYBOARD_H only once, in userspace header * Remove unnecessary initialization in matrix_init_keymap * Do process_record_keymap before cases handled in process_record_user * Reorganize & simplify secrets feature enablement * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Remove superfluous break Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * include "print.h" instead of <print.h> Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_cod16 Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * add #pragma once to a header Co-authored-by: Ryan <fauxpark@gmail.com> * include "print.h" instead of <print.h> Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Use :flash target where possible * Remove special case flash target and use PROGRAM_CMD * dz60/jdelkins_ss: use tap_code16 Co-authored-by: Drashna Jaelre <drashna@live.com> Co-authored-by: Ryan <fauxpark@gmail.com>
3 years ago
[Keymap] merge jdelkins userspace and associated keymaps (#11276) * [Keymap] merge jdelkins userspace and associated keymaps * Add copyright & license info * Change rgblight_config.enable to rgblight_is_enabled() * Update keyboards/dz60/keymaps/jdelkins/keymap.c Co-authored-by: Drashna Jaelre <drashna@live.com> * Update keyboards/dz60/keymaps/jdelkins/keymap.c Co-authored-by: Drashna Jaelre <drashna@live.com> * Update keyboards/dz60/keymaps/jdelkins/keymap.c Co-authored-by: Drashna Jaelre <drashna@live.com> * Remove superfluous includes * Change EXTRAFLAGS+=-flto to LTO_ENABLE=yes * Remove unnecessary jdelkins_ss symlink in users * Add copyright and license notices * Use preferred way to determine capslock / numlock state Co-authored-by: Drashna Jaelre <drashna@live.com> * Add #pragma once to a header Co-authored-by: Drashna Jaelre <drashna@live.com> * Include QMK_KEYBOARD_H only once, in userspace header * Remove unnecessary initialization in matrix_init_keymap * Do process_record_keymap before cases handled in process_record_user * Reorganize & simplify secrets feature enablement * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Remove superfluous break Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * include "print.h" instead of <print.h> Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_cod16 Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * add #pragma once to a header Co-authored-by: Ryan <fauxpark@gmail.com> * include "print.h" instead of <print.h> Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Use :flash target where possible * Remove special case flash target and use PROGRAM_CMD * dz60/jdelkins_ss: use tap_code16 Co-authored-by: Drashna Jaelre <drashna@live.com> Co-authored-by: Ryan <fauxpark@gmail.com>
3 years ago
[Keymap] merge jdelkins userspace and associated keymaps (#11276) * [Keymap] merge jdelkins userspace and associated keymaps * Add copyright & license info * Change rgblight_config.enable to rgblight_is_enabled() * Update keyboards/dz60/keymaps/jdelkins/keymap.c Co-authored-by: Drashna Jaelre <drashna@live.com> * Update keyboards/dz60/keymaps/jdelkins/keymap.c Co-authored-by: Drashna Jaelre <drashna@live.com> * Update keyboards/dz60/keymaps/jdelkins/keymap.c Co-authored-by: Drashna Jaelre <drashna@live.com> * Remove superfluous includes * Change EXTRAFLAGS+=-flto to LTO_ENABLE=yes * Remove unnecessary jdelkins_ss symlink in users * Add copyright and license notices * Use preferred way to determine capslock / numlock state Co-authored-by: Drashna Jaelre <drashna@live.com> * Add #pragma once to a header Co-authored-by: Drashna Jaelre <drashna@live.com> * Include QMK_KEYBOARD_H only once, in userspace header * Remove unnecessary initialization in matrix_init_keymap * Do process_record_keymap before cases handled in process_record_user * Reorganize & simplify secrets feature enablement * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Remove superfluous break Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * include "print.h" instead of <print.h> Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_cod16 Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * add #pragma once to a header Co-authored-by: Ryan <fauxpark@gmail.com> * include "print.h" instead of <print.h> Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Use :flash target where possible * Remove special case flash target and use PROGRAM_CMD * dz60/jdelkins_ss: use tap_code16 Co-authored-by: Drashna Jaelre <drashna@live.com> Co-authored-by: Ryan <fauxpark@gmail.com>
3 years ago
[Keymap] merge jdelkins userspace and associated keymaps (#11276) * [Keymap] merge jdelkins userspace and associated keymaps * Add copyright & license info * Change rgblight_config.enable to rgblight_is_enabled() * Update keyboards/dz60/keymaps/jdelkins/keymap.c Co-authored-by: Drashna Jaelre <drashna@live.com> * Update keyboards/dz60/keymaps/jdelkins/keymap.c Co-authored-by: Drashna Jaelre <drashna@live.com> * Update keyboards/dz60/keymaps/jdelkins/keymap.c Co-authored-by: Drashna Jaelre <drashna@live.com> * Remove superfluous includes * Change EXTRAFLAGS+=-flto to LTO_ENABLE=yes * Remove unnecessary jdelkins_ss symlink in users * Add copyright and license notices * Use preferred way to determine capslock / numlock state Co-authored-by: Drashna Jaelre <drashna@live.com> * Add #pragma once to a header Co-authored-by: Drashna Jaelre <drashna@live.com> * Include QMK_KEYBOARD_H only once, in userspace header * Remove unnecessary initialization in matrix_init_keymap * Do process_record_keymap before cases handled in process_record_user * Reorganize & simplify secrets feature enablement * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Remove superfluous break Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * include "print.h" instead of <print.h> Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_cod16 Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * add #pragma once to a header Co-authored-by: Ryan <fauxpark@gmail.com> * include "print.h" instead of <print.h> Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Use :flash target where possible * Remove special case flash target and use PROGRAM_CMD * dz60/jdelkins_ss: use tap_code16 Co-authored-by: Drashna Jaelre <drashna@live.com> Co-authored-by: Ryan <fauxpark@gmail.com>
3 years ago
[Keymap] merge jdelkins userspace and associated keymaps (#11276) * [Keymap] merge jdelkins userspace and associated keymaps * Add copyright & license info * Change rgblight_config.enable to rgblight_is_enabled() * Update keyboards/dz60/keymaps/jdelkins/keymap.c Co-authored-by: Drashna Jaelre <drashna@live.com> * Update keyboards/dz60/keymaps/jdelkins/keymap.c Co-authored-by: Drashna Jaelre <drashna@live.com> * Update keyboards/dz60/keymaps/jdelkins/keymap.c Co-authored-by: Drashna Jaelre <drashna@live.com> * Remove superfluous includes * Change EXTRAFLAGS+=-flto to LTO_ENABLE=yes * Remove unnecessary jdelkins_ss symlink in users * Add copyright and license notices * Use preferred way to determine capslock / numlock state Co-authored-by: Drashna Jaelre <drashna@live.com> * Add #pragma once to a header Co-authored-by: Drashna Jaelre <drashna@live.com> * Include QMK_KEYBOARD_H only once, in userspace header * Remove unnecessary initialization in matrix_init_keymap * Do process_record_keymap before cases handled in process_record_user * Reorganize & simplify secrets feature enablement * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Remove superfluous break Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * include "print.h" instead of <print.h> Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_cod16 Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * add #pragma once to a header Co-authored-by: Ryan <fauxpark@gmail.com> * include "print.h" instead of <print.h> Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Use :flash target where possible * Remove special case flash target and use PROGRAM_CMD * dz60/jdelkins_ss: use tap_code16 Co-authored-by: Drashna Jaelre <drashna@live.com> Co-authored-by: Ryan <fauxpark@gmail.com>
3 years ago
[Keymap] merge jdelkins userspace and associated keymaps (#11276) * [Keymap] merge jdelkins userspace and associated keymaps * Add copyright & license info * Change rgblight_config.enable to rgblight_is_enabled() * Update keyboards/dz60/keymaps/jdelkins/keymap.c Co-authored-by: Drashna Jaelre <drashna@live.com> * Update keyboards/dz60/keymaps/jdelkins/keymap.c Co-authored-by: Drashna Jaelre <drashna@live.com> * Update keyboards/dz60/keymaps/jdelkins/keymap.c Co-authored-by: Drashna Jaelre <drashna@live.com> * Remove superfluous includes * Change EXTRAFLAGS+=-flto to LTO_ENABLE=yes * Remove unnecessary jdelkins_ss symlink in users * Add copyright and license notices * Use preferred way to determine capslock / numlock state Co-authored-by: Drashna Jaelre <drashna@live.com> * Add #pragma once to a header Co-authored-by: Drashna Jaelre <drashna@live.com> * Include QMK_KEYBOARD_H only once, in userspace header * Remove unnecessary initialization in matrix_init_keymap * Do process_record_keymap before cases handled in process_record_user * Reorganize & simplify secrets feature enablement * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Remove superfluous break Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * include "print.h" instead of <print.h> Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_cod16 Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * add #pragma once to a header Co-authored-by: Ryan <fauxpark@gmail.com> * include "print.h" instead of <print.h> Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Use :flash target where possible * Remove special case flash target and use PROGRAM_CMD * dz60/jdelkins_ss: use tap_code16 Co-authored-by: Drashna Jaelre <drashna@live.com> Co-authored-by: Ryan <fauxpark@gmail.com>
3 years ago
[Keymap] merge jdelkins userspace and associated keymaps (#11276) * [Keymap] merge jdelkins userspace and associated keymaps * Add copyright & license info * Change rgblight_config.enable to rgblight_is_enabled() * Update keyboards/dz60/keymaps/jdelkins/keymap.c Co-authored-by: Drashna Jaelre <drashna@live.com> * Update keyboards/dz60/keymaps/jdelkins/keymap.c Co-authored-by: Drashna Jaelre <drashna@live.com> * Update keyboards/dz60/keymaps/jdelkins/keymap.c Co-authored-by: Drashna Jaelre <drashna@live.com> * Remove superfluous includes * Change EXTRAFLAGS+=-flto to LTO_ENABLE=yes * Remove unnecessary jdelkins_ss symlink in users * Add copyright and license notices * Use preferred way to determine capslock / numlock state Co-authored-by: Drashna Jaelre <drashna@live.com> * Add #pragma once to a header Co-authored-by: Drashna Jaelre <drashna@live.com> * Include QMK_KEYBOARD_H only once, in userspace header * Remove unnecessary initialization in matrix_init_keymap * Do process_record_keymap before cases handled in process_record_user * Reorganize & simplify secrets feature enablement * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Remove superfluous break Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * include "print.h" instead of <print.h> Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_cod16 Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * add #pragma once to a header Co-authored-by: Ryan <fauxpark@gmail.com> * include "print.h" instead of <print.h> Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Use :flash target where possible * Remove special case flash target and use PROGRAM_CMD * dz60/jdelkins_ss: use tap_code16 Co-authored-by: Drashna Jaelre <drashna@live.com> Co-authored-by: Ryan <fauxpark@gmail.com>
3 years ago
[Keymap] merge jdelkins userspace and associated keymaps (#11276) * [Keymap] merge jdelkins userspace and associated keymaps * Add copyright & license info * Change rgblight_config.enable to rgblight_is_enabled() * Update keyboards/dz60/keymaps/jdelkins/keymap.c Co-authored-by: Drashna Jaelre <drashna@live.com> * Update keyboards/dz60/keymaps/jdelkins/keymap.c Co-authored-by: Drashna Jaelre <drashna@live.com> * Update keyboards/dz60/keymaps/jdelkins/keymap.c Co-authored-by: Drashna Jaelre <drashna@live.com> * Remove superfluous includes * Change EXTRAFLAGS+=-flto to LTO_ENABLE=yes * Remove unnecessary jdelkins_ss symlink in users * Add copyright and license notices * Use preferred way to determine capslock / numlock state Co-authored-by: Drashna Jaelre <drashna@live.com> * Add #pragma once to a header Co-authored-by: Drashna Jaelre <drashna@live.com> * Include QMK_KEYBOARD_H only once, in userspace header * Remove unnecessary initialization in matrix_init_keymap * Do process_record_keymap before cases handled in process_record_user * Reorganize & simplify secrets feature enablement * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Remove superfluous break Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * include "print.h" instead of <print.h> Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_cod16 Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * add #pragma once to a header Co-authored-by: Ryan <fauxpark@gmail.com> * include "print.h" instead of <print.h> Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Use :flash target where possible * Remove special case flash target and use PROGRAM_CMD * dz60/jdelkins_ss: use tap_code16 Co-authored-by: Drashna Jaelre <drashna@live.com> Co-authored-by: Ryan <fauxpark@gmail.com>
3 years ago
[Keymap] merge jdelkins userspace and associated keymaps (#11276) * [Keymap] merge jdelkins userspace and associated keymaps * Add copyright & license info * Change rgblight_config.enable to rgblight_is_enabled() * Update keyboards/dz60/keymaps/jdelkins/keymap.c Co-authored-by: Drashna Jaelre <drashna@live.com> * Update keyboards/dz60/keymaps/jdelkins/keymap.c Co-authored-by: Drashna Jaelre <drashna@live.com> * Update keyboards/dz60/keymaps/jdelkins/keymap.c Co-authored-by: Drashna Jaelre <drashna@live.com> * Remove superfluous includes * Change EXTRAFLAGS+=-flto to LTO_ENABLE=yes * Remove unnecessary jdelkins_ss symlink in users * Add copyright and license notices * Use preferred way to determine capslock / numlock state Co-authored-by: Drashna Jaelre <drashna@live.com> * Add #pragma once to a header Co-authored-by: Drashna Jaelre <drashna@live.com> * Include QMK_KEYBOARD_H only once, in userspace header * Remove unnecessary initialization in matrix_init_keymap * Do process_record_keymap before cases handled in process_record_user * Reorganize & simplify secrets feature enablement * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Remove superfluous break Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * include "print.h" instead of <print.h> Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_cod16 Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * add #pragma once to a header Co-authored-by: Ryan <fauxpark@gmail.com> * include "print.h" instead of <print.h> Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * Remove copyright from rules.mk Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Use tap_code16 Co-authored-by: Ryan <fauxpark@gmail.com> * Use :flash target where possible * Remove special case flash target and use PROGRAM_CMD * dz60/jdelkins_ss: use tap_code16 Co-authored-by: Drashna Jaelre <drashna@live.com> Co-authored-by: Ryan <fauxpark@gmail.com>
3 years ago
  1. /*
  2. Copyright 2020 Joel Elkins <joel@elkins.com>
  3. This program is free software: you can redistribute it and/or modify
  4. it under the terms of the GNU General Public License as published by
  5. the Free Software Foundation, either version 2 of the License, or
  6. (at your option) any later version.
  7. This program is distributed in the hope that it will be useful,
  8. but WITHOUT ANY WARRANTY; without even the implied warranty of
  9. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  10. GNU General Public License for more details.
  11. You should have received a copy of the GNU General Public License
  12. along with this program. If not, see <http://www.gnu.org/licenses/>.
  13. */
  14. #include "jdelkins.h"
  15. #include "version.h"
  16. #ifdef DO_SECRETS
  17. # include "secrets.h"
  18. #else
  19. # ifndef NO_SECRETS
  20. # pragma message("Warning: secrets.h not found")
  21. # endif
  22. #endif
  23. user_config_t user_config;
  24. __attribute__ ((weak))
  25. bool process_record_keymap(uint16_t keycode, keyrecord_t *record) {
  26. return true;
  27. }
  28. void send_secret_string(uint8_t n) {
  29. #ifdef DO_SECRETS
  30. send_string(secret[n]);
  31. #else
  32. SEND_STRING("");
  33. #endif
  34. }
  35. #ifdef TAP_DANCE_ENABLE
  36. // To activate SINGLE_HOLD, you will need to hold for 200ms first.
  37. // This tap dance favors keys that are used frequently in typing like 'f'
  38. int cur_dance(qk_tap_dance_state_t *state) {
  39. if (state->count == 1) {
  40. // If count = 1, and it has been interrupted - it doesn't matter if it
  41. // is pressed or not: Send SINGLE_TAP
  42. if (state->interrupted) {
  43. // if (!state->pressed) return SINGLE_TAP;
  44. // need "permissive hold" here.
  45. // else return SINsGLE_HOLD;
  46. // If the interrupting key is released before the tap-dance key,
  47. // then it is a single HOLD However, if the tap-dance key is
  48. // released first, then it is a single TAP But how to get access to
  49. // the state of the interrupting key????
  50. return SINGLE_TAP;
  51. } else {
  52. if (!state->pressed)
  53. return SINGLE_TAP;
  54. else
  55. return SINGLE_HOLD;
  56. }
  57. }
  58. // If count = 2, and it has been interrupted - assume that user is trying to
  59. // type the letter associated with single tap.
  60. else if (state->count == 2) {
  61. if (state->interrupted)
  62. return DOUBLE_SINGLE_TAP;
  63. else if (state->pressed)
  64. return DOUBLE_HOLD;
  65. else
  66. return DOUBLE_TAP;
  67. } else if ((state->count == 3) && ((state->interrupted) || (!state->pressed)))
  68. return TRIPLE_TAP;
  69. else if (state->count == 3)
  70. return TRIPLE_HOLD;
  71. else
  72. return 8; // magic number. At some point this method will expand to work for more presses
  73. }
  74. // This works well if you want this key to work as a "fast modifier". It favors
  75. // being held over being tapped.
  76. int hold_cur_dance(qk_tap_dance_state_t *state) {
  77. if (state->count == 1) {
  78. if (state->interrupted) {
  79. if (!state->pressed)
  80. return SINGLE_TAP;
  81. else
  82. return SINGLE_HOLD;
  83. } else {
  84. if (!state->pressed)
  85. return SINGLE_TAP;
  86. else
  87. return SINGLE_HOLD;
  88. }
  89. }
  90. // If count = 2, and it has been interrupted - assume that user is trying to
  91. // type the letter associated with single tap.
  92. else if (state->count == 2) {
  93. if (state->pressed)
  94. return DOUBLE_HOLD;
  95. else
  96. return DOUBLE_TAP;
  97. } else if (state->count == 3) {
  98. if (!state->pressed)
  99. return TRIPLE_TAP;
  100. else
  101. return TRIPLE_HOLD;
  102. } else
  103. return 8; // magic number. At some point this method will expand to work for more presses
  104. }
  105. #endif // TAP_DANCE_ENABLE
  106. __attribute__ ((weak))
  107. void keyboard_post_init_keymap(void) {
  108. }
  109. void keyboard_post_init_user(void) {
  110. user_config.raw = eeconfig_read_user();
  111. keyboard_post_init_keymap();
  112. }
  113. void eeconfig_init_user(void) {
  114. user_config.raw = 0;
  115. user_config.system_mac = false;
  116. eeconfig_update_user(user_config.raw);
  117. }
  118. bool process_record_user(uint16_t keycode, keyrecord_t *record) {
  119. static uint32_t boot_timer;
  120. if (!process_record_keymap(keycode, record)) {
  121. return false;
  122. }
  123. switch (keycode) {
  124. case FW_WRD:
  125. do_mac_key(LCTL(KC_RIGHT), ROPT(KC_RIGHT), record);
  126. break;
  127. case BK_WRD:
  128. do_mac_key(LCTL(KC_LEFT), ROPT(KC_LEFT), record);
  129. break;
  130. case KB_BOL:
  131. do_mac_key(KC_HOME, RCMD(KC_LEFT), record);
  132. break;
  133. case KB_EOL:
  134. do_mac_key(KC_END, RCMD(KC_RIGHT), record);
  135. break;
  136. case TG_SYS:
  137. if (record->event.pressed) {
  138. user_config.system_mac ^= 1;
  139. eeconfig_update_user(user_config.raw);
  140. }
  141. break;
  142. case KB_COPY:
  143. do_mac_key(LCTL(KC_INS), RCMD(KC_C), record);
  144. break;
  145. case KB_PASTE:
  146. do_mac_key(LSFT(KC_INS), RCMD(KC_V), record);
  147. break;
  148. case MY_GUI:
  149. do_mac_key(KC_LGUI, KC_LOPT, record);
  150. break;
  151. case MY_ALT:
  152. do_mac_key(KC_LALT, KC_LCMD, record);
  153. break;
  154. case MY_RGUI:
  155. do_mac_key(KC_RGUI, KC_ROPT, record);
  156. break;
  157. case MY_RALT:
  158. do_mac_key(KC_RALT, KC_RCMD, record);
  159. break;
  160. case MY_CALC:
  161. do_mac_key(KC_CALC, KC_F14, record);
  162. break;
  163. case KB_MAKE:
  164. if (!get_mods()) {
  165. if (!record->event.pressed)
  166. #ifdef NO_SECRETS
  167. SEND_STRING("make NO_SECRETS=1 " QMK_KEYBOARD ":" QMK_KEYMAP SS_TAP(X_ENTER));
  168. #else
  169. SEND_STRING("make " QMK_KEYBOARD ":" QMK_KEYMAP SS_TAP(X_ENTER));
  170. #endif
  171. return false;
  172. }
  173. break;
  174. case KB_VRSN:
  175. if (!get_mods()) {
  176. if (!record->event.pressed) {
  177. #ifdef DO_SECRETS
  178. # define SECRET_MSG " (with secrets)"
  179. #else
  180. # define SECRET_MSG
  181. #endif
  182. if (user_config.system_mac) {
  183. SEND_STRING(QMK_KEYBOARD "/" QMK_KEYMAP " @ " QMK_VERSION " (mac mode)" SECRET_MSG);
  184. } else {
  185. SEND_STRING(QMK_KEYBOARD "/" QMK_KEYMAP " @ " QMK_VERSION " (non-mac mode)" SECRET_MSG);
  186. }
  187. }
  188. return false;
  189. }
  190. break;
  191. case KB_BOOT:
  192. if (!get_mods()) {
  193. if (record->event.pressed) {
  194. boot_timer = timer_read32();
  195. } else {
  196. if (timer_elapsed32(boot_timer) >= 500) {
  197. reset_keyboard();
  198. }
  199. }
  200. return false;
  201. }
  202. break;
  203. case KB_FLSH:
  204. if (!get_mods()) {
  205. if (!record->event.pressed) {
  206. #ifdef NO_SECRETS
  207. SEND_STRING("make NO_SECRETS=1 " QMK_KEYBOARD ":" QMK_KEYMAP ":flash\n");
  208. #else
  209. SEND_STRING("make " QMK_KEYBOARD ":" QMK_KEYMAP ":flash\n");
  210. #endif
  211. reset_keyboard();
  212. }
  213. return false;
  214. }
  215. break;
  216. #ifdef DO_SECRETS
  217. case KC_SECRET_1 ... KC_SECRET_6: // Secrets! Externally defined strings, not stored in repo
  218. if (!record->event.pressed) {
  219. clear_oneshot_layer_state(ONESHOT_OTHER_KEY_PRESSED);
  220. send_secret_string(keycode - KC_SECRET_1);
  221. }
  222. return false;
  223. break;
  224. #endif
  225. }
  226. return true;
  227. }
  228. __attribute__ ((weak))
  229. void matrix_init_keymap(void) {
  230. }
  231. void matrix_init_user(void) {
  232. matrix_init_keymap();
  233. }
  234. __attribute__ ((weak))
  235. void matrix_scan_keymap(void) {
  236. }
  237. void matrix_scan_user(void) {
  238. matrix_scan_keymap();
  239. }
  240. __attribute__ ((weak))
  241. layer_state_t layer_state_set_keymap(layer_state_t state) {
  242. return state;
  243. }
  244. layer_state_t layer_state_set_user(layer_state_t state) {
  245. return layer_state_set_keymap(state);
  246. }