Skip to content

Commit

Permalink
Update spidey3 layouts to use official KC_CPNL, KC_ASST
Browse files Browse the repository at this point in the history
  • Loading branch information
spidey3 committed Aug 30, 2022
1 parent 774f13c commit 7eee4f6
Show file tree
Hide file tree
Showing 5 changed files with 5 additions and 25 deletions.
13 changes: 1 addition & 12 deletions keyboards/dmqdesign/spin/keymaps/spidey3_pad/keymap.c
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,6 @@ enum layer_base {

enum custom_keycodes {
HELLO = SAFE_RANGE,
CH_CPNL, // AL Control Panel
CH_ASST, // AL Context-aware Desktop Assistant
CH_SUSP, // Suspend
};

Expand All @@ -40,7 +38,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
A(S(KC_N)), HELLO, CH_SUSP, TO(_MACRO),
KC_MPRV, KC_MPLY, KC_MNXT, TO(_NUMPAD),
C(A(KC_COMM)), KC_F5, C(A(KC_DOT)), TO(_RGB),
MO(_FN), CH_ASST, CH_CPNL),
MO(_FN), KC_ASST, KC_CPNL),

[_NUMPAD] = LAYOUT(
KC_KP_7, KC_KP_8, KC_KP_9, KC_TRNS,
Expand Down Expand Up @@ -199,19 +197,10 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
return false;

// clang-format off
case CH_CPNL: host_consumer_send(AL_CONTROL_PANEL); return false;
case CH_ASST: host_consumer_send(AL_ASSISTANT); return false;
case CH_SUSP: tap_code16(LGUI(LSFT(KC_L))); return true;
case HELLO: SEND_STRING("Hello, world!"); return true;
// clang-format on
}
} else {
switch (keycode) {
case CH_CPNL:
case CH_ASST:
host_consumer_send(0);
return false;
}
}

return true;
Expand Down
4 changes: 2 additions & 2 deletions layouts/community/65_ansi_blocker/spidey3/keymap.c
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,9 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[_FN] = LAYOUT_65_ansi_blocker(
KC_GRV, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_INS, KC_SLCK,
XXXXXXX, RGB_TOG, RGB_MOD, RGB_HUD, RGB_HUI, RGB_SAD, RGB_SAI, RGB_VAD, RGB_VAI, SPI_GLO, VLK_TOG, CH_SUSP, KC_SLEP, KC_PWR, KC_BRIU,
MO(_GLYPH), RGB_M_P, RGB_M_B, RGB_M_R, RGB_M_SW, RGB_M_SN, RGB_M_K, RGB_M_G, RGB_M_TW, UC_M_LN, XXXXXXX, XXXXXXX, CH_CPNL, KC_BRID,
MO(_GLYPH), RGB_M_P, RGB_M_B, RGB_M_R, RGB_M_SW, RGB_M_SN, RGB_M_K, RGB_M_G, RGB_M_TW, UC_M_LN, XXXXXXX, XXXXXXX, KC_CPNL, KC_BRID,
_______, XXXXXXX, UC_M_EM, UC_M_WC, UC_MOD, NK_TOGG, TG(_NUMPAD),UC_M_MA, XXXXXXX, XXXXXXX, DEBUG, _______, KC_VOLU, KC_MUTE,
_______, _______, _______, KC_MPLY, CH_ASST, _______, KC_MPRV, KC_VOLD, KC_MNXT
_______, _______, _______, KC_MPLY, KC_ASST, _______, KC_MPRV, KC_VOLD, KC_MNXT
),
// Glyph Transformation
[_GLYPH] = LAYOUT_65_ansi_blocker(
Expand Down
2 changes: 1 addition & 1 deletion layouts/community/75_ansi/spidey3/keymap.c
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,6 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
XXXXXXX, RGB_TOG, RGB_MOD, RGB_HUD, RGB_HUI, RGB_SAD, RGB_SAI, RGB_VAD, RGB_VAI, SPI_GLO, VLK_TOG, XXXXXXX, XXXXXXX, XXXXXXX, KC_BRIU,
XXXXXXX, RGB_M_P, RGB_M_B, RGB_M_R, RGB_M_SW, RGB_M_SN, RGB_M_K, RGB_M_G, RGB_M_TW, UC_M_LN, XXXXXXX, XXXXXXX, XXXXXXX, KC_BRID,
_______, XXXXXXX, UC_M_EM, UC_M_WC, UC_MOD, NK_TOGG, TG(_NUMPAD),UC_M_MA, X(LARR), X(RARR), DEBUG, _______, KC_VOLU, KC_MUTE,
_______, _______, _______, KC_MPLY, CH_ASST, _______, CH_CPNL, KC_MPRV, KC_VOLD, KC_MNXT
_______, _______, _______, KC_MPLY, KC_ASST, _______, KC_CPNL, KC_MPRV, KC_VOLD, KC_MNXT
)
};
7 changes: 0 additions & 7 deletions users/spidey3/spidey3.c
Original file line number Diff line number Diff line change
Expand Up @@ -199,8 +199,6 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {

// clang-format off

case CH_CPNL: host_consumer_send(AL_CONTROL_PANEL); return false;
case CH_ASST: host_consumer_send(AL_ASSISTANT); return false;
case CH_SUSP: tap_code16(LGUI(LSFT(KC_L))); return true;

// clang-format on
Expand Down Expand Up @@ -285,11 +283,6 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
}
} else {
switch (keycode) {
case CH_CPNL:
case CH_ASST:
host_consumer_send(0);
return false;

case SPI_KP_00:
unregister_code(KC_KP_0);
return false;
Expand Down
4 changes: 1 addition & 3 deletions users/spidey3/spidey3.h
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,7 @@ enum userspace_layers {
};

enum custom_keycodes {
CH_CPNL = SAFE_RANGE, // AL Control Panel
CH_ASST, // AL Context-aware Desktop Assistant
CH_SUSP, // Suspend
CH_SUSP = SAFE_RANGE, // Suspend

SPI_NORMAL,
SPI_WIDE,
Expand Down

0 comments on commit 7eee4f6

Please sign in to comment.