jtroo / kanata

Improve keyboard comfort and usability with advanced customization
GNU Lesser General Public License v3.0
3.23k stars 131 forks source link

See if windows shift workaround can be compiled out for winiov2 #1104

Closed jtroo closed 5 months ago

jtroo commented 5 months ago
    pub fn check_release_non_physical_shift(&mut self) -> Result<()> {
jtroo commented 5 months ago
> [console]::NumberLock
True

no scancode feature

20:35:07.8211 [DEBUG] (1) kanata_state_machine::kanata::windows::llhook: event loop: KeyEvent { code: KEY_1, value: Press }
20:35:07.8242 [DEBUG] (2) kanata_state_machine::kanata: process recv ev KeyEvent { code: KEY_1, value: Press }
20:35:07.8253 [DEBUG] (2) kanata_state_machine::kanata: key press     LShift
20:35:08.2599 [DEBUG] (1) kanata_state_machine::kanata::windows::llhook: event loop: KeyEvent { code: KEY_2, value: Press }
20:35:08.2630 [DEBUG] (2) kanata_state_machine::kanata: process recv ev KeyEvent { code: KEY_2, value: Press }
20:35:08.2643 [DEBUG] (2) kanata_state_machine::kanata: key press     Left
20:35:08.2656 [DEBUG] (1) kanata_state_machine::kanata::windows::llhook: event loop: KeyEvent { code: KEY_LEFTSHIFT, value: Release }
20:35:08.2683 [DEBUG] (2) kanata_state_machine::kanata: process recv ev KeyEvent { code: KEY_LEFTSHIFT, value: Release }
20:35:08.3463 [DEBUG] (1) kanata_state_machine::kanata::windows::llhook: event loop: KeyEvent { code: KEY_LEFTSHIFT, value: Press }
20:35:08.3484 [DEBUG] (1) kanata_state_machine::kanata::windows::llhook: event loop: KeyEvent { code: KEY_2, value: Release }
20:35:08.3499 [DEBUG] (2) kanata_state_machine::kanata: process recv ev KeyEvent { code: KEY_LEFTSHIFT, value: Press }
20:35:08.3513 [DEBUG] (2) kanata_state_machine::kanata: process recv ev KeyEvent { code: KEY_2, value: Release }
20:35:08.3526 [DEBUG] (2) kanata_state_machine::kanata: key release   Left
20:35:08.3540 [DEBUG] (1) kanata_state_machine::kanata::windows::llhook: event loop: KeyEvent { code: KEY_LEFTSHIFT, value: Release }
20:35:08.3566 [DEBUG] (2) kanata_state_machine::kanata: process recv ev KeyEvent { code: KEY_LEFTSHIFT, value: Release }
20:35:08.7443 [DEBUG] (1) kanata_state_machine::kanata::windows::llhook: event loop: KeyEvent { code: KEY_LEFTSHIFT, value: Press }
20:35:08.7460 [DEBUG] (1) kanata_state_machine::kanata::windows::llhook: event loop: KeyEvent { code: KEY_1, value: Release }
20:35:08.7473 [DEBUG] (2) kanata_state_machine::kanata: process recv ev KeyEvent { code: KEY_LEFTSHIFT, value: Press }
20:35:08.7489 [DEBUG] (2) kanata_state_machine::kanata: process recv ev KeyEvent { code: KEY_1, value: Release }
20:35:08.7502 [DEBUG] (2) kanata_state_machine::kanata::windows: lsft-arrowkey workaround: removing LShift at its typical coordinate
20:35:08.7515 [DEBUG] (2) kanata_state_machine::kanata::windows: removing LShift from pressed keys
20:35:08.7524 [DEBUG] (2) kanata_state_machine::kanata: key release   LShift

with --features=win_sendinput_send_scancodes:

20:36:37.9486 [DEBUG] (1) kanata_state_machine::kanata::windows::llhook: event loop: KeyEvent { code: KEY_1, value: Press }
20:36:37.9509 [DEBUG] (2) kanata_state_machine::kanata: process recv ev KeyEvent { code: KEY_1, value: Press }
20:36:37.9519 [DEBUG] (2) kanata_state_machine::kanata: key press     LShift
20:36:38.3393 [DEBUG] (1) kanata_state_machine::kanata::windows::llhook: event loop: KeyEvent { code: KEY_2, value: Press }
20:36:38.3415 [DEBUG] (2) kanata_state_machine::kanata: process recv ev KeyEvent { code: KEY_2, value: Press }
20:36:38.3427 [DEBUG] (2) kanata_state_machine::kanata: key press     Left
20:36:38.3944 [DEBUG] (1) kanata_state_machine::kanata::windows::llhook: event loop: KeyEvent { code: KEY_2, value: Release }
20:36:38.3968 [DEBUG] (2) kanata_state_machine::kanata: process recv ev KeyEvent { code: KEY_2, value: Release }
20:36:38.3980 [DEBUG] (2) kanata_state_machine::kanata: key release   Left
20:36:39.4154 [DEBUG] (1) kanata_state_machine::kanata::windows::llhook: event loop: KeyEvent { code: KEY_1, value: Release }
20:36:39.4178 [DEBUG] (2) kanata_state_machine::kanata: process recv ev KeyEvent { code: KEY_1, value: Release }
20:36:39.4190 [DEBUG] (2) kanata_state_machine::kanata: key release   LShift
20:36:39.4207 [DEBUG] (2) kanata_state_machine::kanata::windows: lsft-arrowkey workaround: removing LShift at its typical coordinate
20:36:39.4218 [DEBUG] (2) kanata_state_machine::kanata::windows: removing LShift from pressed keys

With numlock False both have the same output. Seems like it can be compiled out.