susam / uncap

Map Caps Lock to Escape or any key to any key
MIT License
1.07k stars 43 forks source link

Version 0.3.0 doesn't work with Logitech Options 'Advanced Click' #10

Open flycal6 opened 5 years ago

flycal6 commented 5 years ago

Uncap version 0.3.0 Ran as Win+R : uncap 0x14:0xa2 0xa2:0x14 (swap caps lock and left control)

In Logitech Options, setting a button as Advanced Click; Single click + 'CTRL' modifer, the advanced click is not registering the CTRL modifier, and fires as a regular click.

This was working as expected in the previous release 0.2.2

ps. thanks for the great software that doesn't require admin

susam commented 5 years ago

Hi Brian (@flycal6),

Thank you for reporting this issue. I am suspecting that this issue is being caused by commit 78f52d7b2e03fc51885c8072d53ff5d41fbe3ffc which added support for mapping injected key events in order to resolve issue #3.

Could you please keep both copies of Uncap (versions 0.2.2 and 0.3.0) on your system, run each one in debug mode and provide me the debug logs?

Here is how you can run Uncap in debug mode:

uncap -d

It would run in a console. Then please perform the advanced click like you normally do and provide me the debug logs that you get in the uncap -d output. Please do this twice: once for Uncap 0.2.2 and again for Uncap 0.3.0. The debug output would help me to narrow down the cause of the issue.

Also, thank you for your kind words on the software. I am glad you like it.

susam commented 5 years ago

On a second look, it looks unlikely that commit 78f52d7b2e03fc51885c8072d53ff5d41fbe3ffc could cause this issue. I would need the debug logs to be sure.

I believe the first thing worth testing would be if Uncap 0.3.0 is able to map any keys at all for you.

For example, if you run the following command, does it swap A and B for you?

uncap 0x41:0x42 0x42:0x41

If this straightforward mapping also fails, then could you please check the section "Known Issue with Microsoft Edge on Windows 10" in the README and confirm or rule out this issue?

flycal6 commented 5 years ago

Uncap version 0.3.0 does swap keys as expected.

Version 0.2.2 ran as WIN+R : uncap -d 0x14:0xa2 0xa2:0x14: Advanced Click (ctrl+click):

KEYDOWN    -   INJ -   -    29 162 (0xA2)
KEYUP      -   INJ -   UP   29 162 (0xA2)

Same as above but with version 0.3.0:

KEYDOWN      0     0  16 -   -   INJ -   -    29 162 (0xA2)
KEYDOWN      0 35963  16 -   -   INJ -   -     0  20 (0x14)
KEYUP        0     0 144 -   -   INJ -   UP   29 162 (0xA2)
KEYUP        0 35963 144 -   -   INJ -   UP    0  20 (0x14)