From 415d683ea71d516dd2a7d4f2f8e43eb4e3e993cb Mon Sep 17 00:00:00 2001 From: Ryan Date: Mon, 11 Jan 2021 20:25:45 +1100 Subject: Remove unused `action_get_macro()` usages in user files (#11165) --- layouts/community/60_iso/unxmaal/keymap.c | 15 --------------- 1 file changed, 15 deletions(-) (limited to 'layouts/community/60_iso') diff --git a/layouts/community/60_iso/unxmaal/keymap.c b/layouts/community/60_iso/unxmaal/keymap.c index 9441997b4b..5c8325e62f 100644 --- a/layouts/community/60_iso/unxmaal/keymap.c +++ b/layouts/community/60_iso/unxmaal/keymap.c @@ -119,21 +119,6 @@ const uint16_t PROGMEM fn_actions[] = { [12] = ACTION_FUNCTION(SHIFT_ESC), }; -const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt) -{ - // MACRODOWN only works in this function - switch(id) { - case 0: - if (record->event.pressed) { - register_code(KC_RSFT); - } else { - unregister_code(KC_RSFT); - } - break; - } - return MACRO_NONE; -}; - void matrix_scan_user(void) { // Layer LED indicators -- cgit v1.2.3 From a07c2a137708f8e2b6e1440d386569b97d613cc5 Mon Sep 17 00:00:00 2001 From: Joel Challis Date: Fri, 22 Jan 2021 19:32:10 +0000 Subject: Remove QMK_KEYBOARD_CONFIG_H (#11576) --- layouts/community/60_iso/unxmaal/config.h | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) (limited to 'layouts/community/60_iso') diff --git a/layouts/community/60_iso/unxmaal/config.h b/layouts/community/60_iso/unxmaal/config.h index 7a500b1bb5..4a90186ee9 100644 --- a/layouts/community/60_iso/unxmaal/config.h +++ b/layouts/community/60_iso/unxmaal/config.h @@ -15,10 +15,7 @@ You should have received a copy of the GNU General Public License along with this program. If not, see . */ -#ifndef KEYMAP_CONFIG_H -#define KEYMAP_CONFIG_H - -#include QMK_KEYBOARD_CONFIG_H +#pragma once #ifndef RGB_DI_PIN #define RGB_DI_PIN F4 @@ -28,5 +25,3 @@ along with this program. If not, see . #define RGBLIGHT_SAT_STEP 8 #define RGBLIGHT_VAL_STEP 8 #endif - -#endif -- cgit v1.2.3 From e0769ea71d1cf4dbc125de0ff0a2e83ec7b8c52a Mon Sep 17 00:00:00 2001 From: Zach White Date: Sat, 16 Jan 2021 18:38:50 -0800 Subject: strip fn_actions --- layouts/community/60_iso/unxmaal/keymap.c | 101 +----------------------------- 1 file changed, 2 insertions(+), 99 deletions(-) (limited to 'layouts/community/60_iso') diff --git a/layouts/community/60_iso/unxmaal/keymap.c b/layouts/community/60_iso/unxmaal/keymap.c index 5c8325e62f..e1c0454fb6 100644 --- a/layouts/community/60_iso/unxmaal/keymap.c +++ b/layouts/community/60_iso/unxmaal/keymap.c @@ -90,37 +90,12 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { [_UL] = LAYOUT_60_iso( KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS, \ KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS, \ - KC_TRNS,F(4),F(5),KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS, \ - KC_TRNS,KC_TRNS,KC_TRNS,F(6),F(7),F(8),F(9),F(10),F(11),KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS, \ + KC_TRNS,RGB_TOG,RGB_MOD,KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS, \ + KC_TRNS,KC_TRNS,KC_TRNS,RGB_HUI,RGB_HUD,RGB_SAI,RGB_SAD,RGB_VAI,RGB_VAD,KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS, \ KC_TRNS,KC_TRNS,KC_TRNS, KC_TRNS, KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS), }; -enum function_id { - RGBLED_TOGGLE, - RGBLED_STEP_MODE, - RGBLED_INCREASE_HUE, - RGBLED_DECREASE_HUE, - RGBLED_INCREASE_SAT, - RGBLED_DECREASE_SAT, - RGBLED_INCREASE_VAL, - RGBLED_DECREASE_VAL, - SHIFT_ESC, -}; - -const uint16_t PROGMEM fn_actions[] = { - [4] = ACTION_FUNCTION(RGBLED_TOGGLE), //Turn on/off underglow - [5] = ACTION_FUNCTION(RGBLED_STEP_MODE), // Change underglow mode - [6] = ACTION_FUNCTION(RGBLED_INCREASE_HUE), - [7] = ACTION_FUNCTION(RGBLED_DECREASE_HUE), - [8] = ACTION_FUNCTION(RGBLED_INCREASE_SAT), - [9] = ACTION_FUNCTION(RGBLED_DECREASE_SAT), - [10] = ACTION_FUNCTION(RGBLED_INCREASE_VAL), - [11] = ACTION_FUNCTION(RGBLED_DECREASE_VAL), - [12] = ACTION_FUNCTION(SHIFT_ESC), -}; - void matrix_scan_user(void) { - // Layer LED indicators // ESC led on when in function layer, WASD cluster leds enabled when on arrow cluster #ifdef KEYBOARD_gh60 @@ -138,75 +113,3 @@ void matrix_scan_user(void) { } #endif }; - -#define MODS_CTRL_MASK (MOD_BIT(KC_LSHIFT)|MOD_BIT(KC_RSHIFT)) - -void action_function(keyrecord_t *record, uint8_t id, uint8_t opt) { - switch (id) { -#ifdef RGBLIGHT_ENABLE - case RGBLED_TOGGLE: - //led operations - if (record->event.pressed) { - rgblight_toggle(); - } - break; - case RGBLED_INCREASE_HUE: - if (record->event.pressed) { - rgblight_increase_hue(); - } - break; - case RGBLED_DECREASE_HUE: - if (record->event.pressed) { - rgblight_decrease_hue(); - } - break; - case RGBLED_INCREASE_SAT: - if (record->event.pressed) { - rgblight_increase_sat(); - } - break; - case RGBLED_DECREASE_SAT: - if (record->event.pressed) { - rgblight_decrease_sat(); - } - break; - case RGBLED_INCREASE_VAL: - if (record->event.pressed) { - rgblight_increase_val(); - } - break; - case RGBLED_DECREASE_VAL: - if (record->event.pressed) { - rgblight_decrease_val(); - } - break; - case RGBLED_STEP_MODE: - if (record->event.pressed) { - rgblight_step(); - } - break; -#endif - static uint8_t shift_esc_shift_mask; - // Shift + ESC = ~ - case SHIFT_ESC: - shift_esc_shift_mask = get_mods()&MODS_CTRL_MASK; - if (record->event.pressed) { - if (shift_esc_shift_mask) { - add_key(KC_GRV); - send_keyboard_report(); - } else { - add_key(KC_ESC); - send_keyboard_report(); - } - } else { - if (shift_esc_shift_mask) { - del_key(KC_GRV); - send_keyboard_report(); - } else { - del_key(KC_ESC); - send_keyboard_report(); - } - } - break; - } -}; -- cgit v1.2.3