summaryrefslogtreecommitdiff
path: root/users/drashna/pointing
diff options
context:
space:
mode:
authorDrashna Jaelre <drashna@live.com>2022-01-30 13:20:33 -0800
committerGitHub <noreply@github.com>2022-01-30 13:20:33 -0800
commit941b1d35b8e40a9c93301a1131ef3f3336fee0b5 (patch)
tree54c8d1ec131d5c8a6e0dd89364a9840b3925fcdd /users/drashna/pointing
parent3555ee0555c8a9ff8aea2a101ae02a72b0e76076 (diff)
[Keymap] Add oled improvements and cnano keymap for drashna (#16133)
Diffstat (limited to 'users/drashna/pointing')
-rw-r--r--users/drashna/pointing/pointing.c20
1 files changed, 11 insertions, 9 deletions
diff --git a/users/drashna/pointing/pointing.c b/users/drashna/pointing/pointing.c
index 0116ce0900..0dcfe73f34 100644
--- a/users/drashna/pointing/pointing.c
+++ b/users/drashna/pointing/pointing.c
@@ -42,19 +42,15 @@ report_mouse_t pointing_device_task_user(report_mouse_t mouse_report) {
layer_on(_MOUSE);
}
}
- }
- return pointing_device_task_keymap(mouse_report);
-}
-
-void matrix_scan_pointing(void) {
- if (timer_elapsed(mouse_timer) > 650 && layer_state_is(_MOUSE) && !mouse_keycode_tracker && !tap_toggling) {
+ } else if (timer_elapsed(mouse_timer) > 650 && layer_state_is(_MOUSE) && !mouse_keycode_tracker && !tap_toggling) {
layer_off(_MOUSE);
- }
- if (tap_toggling) {
+ } else if (tap_toggling) {
if (!layer_state_is(_MOUSE)) {
layer_on(_MOUSE);
}
}
+
+ return pointing_device_task_keymap(mouse_report);
}
bool process_record_pointing(uint16_t keycode, keyrecord_t* record) {
@@ -86,7 +82,7 @@ bool process_record_pointing(uint16_t keycode, keyrecord_t* record) {
case MO(_MOUSE):
#if defined(KEYBOARD_ploopy) || defined(KEYBOARD_handwired_tractyl_manuform)
case DPI_CONFIG:
-#elif defined(KEYBOARD_bastardkb_charybdis)
+#elif defined(KEYBOARD_bastardkb_charybdis) && !defined(NO_CHARYBDIS_KEYCODES)
case SAFE_RANGE ... (CHARYBDIS_SAFE_RANGE-1):
#endif
case KC_MS_UP ... KC_MS_WH_RIGHT:
@@ -98,6 +94,12 @@ bool process_record_pointing(uint16_t keycode, keyrecord_t* record) {
record->event.pressed ? mouse_keycode_tracker++ : mouse_keycode_tracker--;
mouse_timer = timer_read();
break;
+ case QK_ONE_SHOT_MOD ... QK_ONE_SHOT_MOD_MAX:
+ break;
+ case QK_MOD_TAP ... QK_MOD_TAP_MAX:
+ if (record->event.pressed || !record->tap.count) {
+ break;
+ }
default:
if (IS_NOEVENT(record->event)) break;
if ((keycode >= QK_LAYER_TAP && keycode <= QK_LAYER_TAP_MAX) && (((keycode >> 0x8) & 0xF) == _MOUSE)) {