keymap.c (1488B)
1 #include QMK_KEYBOARD_H 2 3 enum tapdance_keycodes { 4 TD_KEY_1, 5 TD_KEY_2, 6 }; 7 8 void dance_key_one (tap_dance_state_t *state, void *user_data) { 9 if (state->count == 1) { 10 send_unicode_string("¯\\_(ツ)_/¯"); 11 tap_code(KC_ENTER); 12 reset_tap_dance (state); 13 } else if (state->count == 2) { 14 unicode_input_mode_step(); 15 reset_tap_dance (state); 16 } 17 } 18 19 void dance_key_two (tap_dance_state_t *state, void *user_data) { 20 if (state->count == 1) { 21 send_unicode_string("ಠ_ಠ"); 22 tap_code(KC_ENTER); 23 reset_tap_dance (state); 24 } else if (state->count == 2) { 25 send_unicode_string("(ノಠ痊ಠ)ノ彡┻━┻"); 26 tap_code(KC_ENTER); 27 reset_tap_dance (state); 28 } else if (state->count == 3) { 29 send_unicode_string("╭∩╮(-_-)╭∩╮"); 30 tap_code(KC_ENTER); 31 reset_tap_dance (state); 32 } else if (state->count == 4) { 33 send_unicode_string("(づ ̄ ³ ̄)づ"); 34 tap_code(KC_ENTER); 35 reset_tap_dance (state); 36 } else if (state->count == 5) { 37 send_unicode_string("(︺︹︺)"); 38 tap_code(KC_ENTER); 39 reset_tap_dance (state); 40 } 41 } 42 43 tap_dance_action_t tap_dance_actions[] = { 44 [TD_KEY_1] = ACTION_TAP_DANCE_FN(dance_key_one), 45 [TD_KEY_2] = ACTION_TAP_DANCE_FN(dance_key_two), 46 }; 47 48 const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { 49 [0] = LAYOUT( 50 TD(TD_KEY_1), 51 TD(TD_KEY_2) 52 ), 53 };