diff options
author | Drashna Jael're <drashna@live.com> | 2020-01-14 17:48:23 -0800 |
---|---|---|
committer | Florian Didron <fdidron@users.noreply.github.com> | 2020-02-26 10:15:12 +0900 |
commit | 5ed3ecdd73913ee484777ab33840f3ece5d3571f (patch) | |
tree | fefde0dbeadfa6cbf379e63784fdc5b48c769431 /keyboards/planck | |
parent | 259cc072029c3358827c7ef6c2462a3d4a6a1f52 (diff) |
Add toggle for live training
Diffstat (limited to 'keyboards/planck')
-rw-r--r-- | keyboards/planck/ez/ez.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/keyboards/planck/ez/ez.c b/keyboards/planck/ez/ez.c index fdb470b2e2..1e8a9d4e12 100644 --- a/keyboards/planck/ez/ez.c +++ b/keyboards/planck/ez/ez.c @@ -247,11 +247,11 @@ uint32_t layer_state_set_kb(uint32_t state) { planck_ez_right_led_off(); state = layer_state_set_user(state); uint8_t layer = biton32(state); -#ifdef WEBUSB_ENABLE - if(webusb_state.paired == true) { +#ifdef ORXY_ENABLE + if(is_oryx_live_training_enabled()) { uint8_t event[4]; event[0] = WEBUSB_STATUS_OK; - event[1] = WEBUSB_EVT_LAYER; + event[1] = ORYX_EVT_LAYER; event[2] = layer; event[3] = WEBUSB_STOP_BIT; webusb_send(event, sizeof(event)); @@ -275,11 +275,11 @@ uint32_t layer_state_set_kb(uint32_t state) { } bool process_record_kb(uint16_t keycode, keyrecord_t *record) { -#ifdef WEBUSB_ENABLE - if(webusb_state.paired == true) { +#ifdef ORYX_ENABLE + if(is_oryx_live_training_enabled()) { uint8_t event[5]; event[0] = WEBUSB_STATUS_OK; - event[1] = record->event.pressed ? WEBUSB_EVT_KEYDOWN : WEBUSB_EVT_KEYUP; + event[1] = record->event.pressed ? ORYX_EVT_KEYDOWN : ORYX_EVT_KEYUP; event[2] = record->event.key.col; event[3] = record->event.key.row; event[4] = WEBUSB_STOP_BIT; |