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

TouchId::is_primary should be on a PointerEvent directly #3943

Open
kchibisov opened this issue Oct 10, 2024 · 0 comments · May be fixed by #3947
Open

TouchId::is_primary should be on a PointerEvent directly #3943

kchibisov opened this issue Oct 10, 2024 · 0 comments · May be fixed by #3947
Labels
S - api Design and usability

Comments

@kchibisov
Copy link
Member

Just by reading the docs on the PointerEvent it seems like the whole purpose of the is_primary is to filter out events that won't have compatibility mouse events (like other touch points, etc), and e.g. work with only mouse-like input.

However given that winit uses its on FingerId the whole point is kind of missing, given that
users have to identify that it's touch, and at this point, they can just check if the given finger already did input.

So, it should just be moved to PointerEvent stuff we have, and set to true for mouse, and for the first finger touching the surface on Touch.

@kchibisov kchibisov added the S - api Design and usability label Oct 10, 2024
@kchibisov kchibisov changed the title TouchId::is_primary should be on a PointerEvent's directly TouchId::is_primary should be on a PointerEvent directly Oct 10, 2024
kchibisov added a commit that referenced this issue Oct 11, 2024
Whether the pointer event is primary or not generally matters for the
context where all input is done by the same event, so users can
_ignore_ non-primary events since they are likely from users clicking
something else with their other fingers.

Having it only on a FingerId made it useless, since it's usually used
to avoid multi-touch, but if you start mapping on touch event you
already can track things like that yourself.

Fixes #3943.
@kchibisov kchibisov linked a pull request Oct 11, 2024 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S - api Design and usability
Development

Successfully merging a pull request may close this issue.

1 participant