2018-08-31 14:49:18 -07:00
|
|
|
#include "mechmerlin.h"
|
2021-10-05 16:49:50 -07:00
|
|
|
#include "version.h"
|
|
|
|
|
2018-08-31 14:49:18 -07:00
|
|
|
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
|
|
|
static uint16_t fnx_layer_timer;
|
|
|
|
|
|
|
|
switch (keycode){
|
|
|
|
case KC_FNX:
|
|
|
|
if(record->event.pressed){
|
|
|
|
fnx_layer_timer = timer_read();
|
|
|
|
layer_on(_FL);
|
|
|
|
} else {
|
|
|
|
layer_off(_FL);
|
|
|
|
if (timer_elapsed(fnx_layer_timer) < 150) {
|
|
|
|
layer_invert(_AL);
|
|
|
|
}
|
|
|
|
}
|
2020-02-03 13:37:01 -08:00
|
|
|
break;
|
2021-10-05 16:49:50 -07:00
|
|
|
case KC_VER:
|
2020-02-03 13:37:01 -08:00
|
|
|
if (record->event.pressed) {
|
2021-10-05 16:49:50 -07:00
|
|
|
send_string_with_delay_P(PSTR(QMK_KEYBOARD "/" QMK_KEYMAP " @ " QMK_VERSION ", Built on: " QMK_BUILDDATE), TAP_CODE_DELAY);
|
2020-02-03 13:37:01 -08:00
|
|
|
} else {
|
|
|
|
}
|
|
|
|
break;
|
2018-08-31 14:49:18 -07:00
|
|
|
}
|
|
|
|
return true;
|
2023-03-15 08:47:12 -07:00
|
|
|
}
|