Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix remapping values bleeding from last entry, set input props same as the original device. #25

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

shinyquagsire23
Copy link

I ran into a bug with this config,

devices:
- input_name: 'ELAN9038:00 04F3:261A Pen'
  output_name: remap-pen
  remappings:
    'BTN_TOOL_RUBBER': [
         {'code': 'BTN_TOOL_PEN', 'value': 0},
         {'code': 'BTN_TOOL_RUBBER'}
    ]

where the BTN_TOOL_PEN entry would set event.value to 0 and the following entry would not actually set BTN_TOOL_RUBBER to the original event value but would keep it 0. The intended effect was to always unset BTN_TOOL_PEN if BTN_TOOL_RUBBER is ever set or unset. I also fixed another issue where device properties wouldn't be set, which was needed since this device is a stylus pen for a touchscreen and it had INPUT_PROP_DIRECT set.

@philipl
Copy link
Owner

philipl commented Sep 13, 2020

Thanks for doing this. Could I ask you to split it into two changes for clarity please?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants