Skip to content

macOS doubleclick fires two doubleclick events #120

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

Closed
s1hofmann opened this issue May 10, 2022 · 0 comments · Fixed by #121
Closed

macOS doubleclick fires two doubleclick events #120

s1hofmann opened this issue May 10, 2022 · 0 comments · Fixed by #121
Assignees
Labels
bug Something isn't working

Comments

@s1hofmann
Copy link
Member

Version
2.1.7-next.20220428185132

Short overview
The macOS mouse doubleclick implementation fires two doubleclick events instead of just one

Detailed error description
Instead of

mouse down -> mouse up -> mouse down -> mouse up -> double click

it is

mouse down -> mouse up -> double click -> mouse down -> mouse up -> double click

@s1hofmann s1hofmann added the bug Something isn't working label May 10, 2022
@s1hofmann s1hofmann self-assigned this May 10, 2022
s1hofmann added a commit that referenced this issue May 10, 2022
s1hofmann added a commit that referenced this issue May 10, 2022
s1hofmann added a commit that referenced this issue May 13, 2022
… by tracking intervals between different click events
s1hofmann added a commit that referenced this issue May 13, 2022
* (#120) Only set kCGMouseEventClickState = 2 on second click to fire a single doubleclick event after two clicks

* (#120) Extend toggleMouse such that it manually handles double clicks by tracking intervals between different click events

* (#120) Added explanatory comment on custom doubleclick implementation
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant