diff options
Diffstat (limited to 'users/drashna/transport_sync.c')
| -rw-r--r-- | users/drashna/transport_sync.c | 17 |
1 files changed, 8 insertions, 9 deletions
diff --git a/users/drashna/transport_sync.c b/users/drashna/transport_sync.c index baa1f7651..8a3e6d1bf 100644 --- a/users/drashna/transport_sync.c +++ b/users/drashna/transport_sync.c | |||
| @@ -1,10 +1,10 @@ | |||
| 1 | #ifdef SPLIT_TRANSACTION_IDS_USER | 1 | #ifdef SPLIT_TRANSACTION_IDS_USER |
| 2 | #include "transport_sync.h" | 2 | # include "transport_sync.h" |
| 3 | #include "transactions.h" | 3 | # include "transactions.h" |
| 4 | #include <string.h> | 4 | # include <string.h> |
| 5 | 5 | ||
| 6 | typedef struct { | 6 | typedef struct { |
| 7 | bool oled_on; | 7 | bool oled_on; |
| 8 | uint16_t keymap_config; | 8 | uint16_t keymap_config; |
| 9 | } user_runtime_config_t; | 9 | } user_runtime_config_t; |
| 10 | 10 | ||
| @@ -23,20 +23,19 @@ void keyboard_post_init_transport_sync(void) { | |||
| 23 | 23 | ||
| 24 | void user_state_update(void) { | 24 | void user_state_update(void) { |
| 25 | if (is_keyboard_master()) { | 25 | if (is_keyboard_master()) { |
| 26 | 26 | # ifdef OLED_DRIVER_ENABLE | |
| 27 | #ifdef OLED_DRIVER_ENABLE | ||
| 28 | user_state.oled_on = is_oled_on(); | 27 | user_state.oled_on = is_oled_on(); |
| 29 | #endif | 28 | # endif |
| 30 | 29 | ||
| 31 | user_state.keymap_config = keymap_config.raw; | 30 | user_state.keymap_config = keymap_config.raw; |
| 32 | } else { | 31 | } else { |
| 33 | #ifdef OLED_DRIVER_ENABLE | 32 | # ifdef OLED_DRIVER_ENABLE |
| 34 | if (user_state.oled_on) { | 33 | if (user_state.oled_on) { |
| 35 | oled_on(); | 34 | oled_on(); |
| 36 | } else { | 35 | } else { |
| 37 | oled_off(); | 36 | oled_off(); |
| 38 | } | 37 | } |
| 39 | #endif | 38 | # endif |
| 40 | if (keymap_config.raw != user_state.keymap_config) { | 39 | if (keymap_config.raw != user_state.keymap_config) { |
| 41 | keymap_config.raw = user_state.keymap_config; | 40 | keymap_config.raw = user_state.keymap_config; |
| 42 | } | 41 | } |
