Skip to content

webdriver: Implement Pointer ID#39642

Merged
yezhizhen merged 2 commits intoservo:mainfrom
yezhizhen:add-pointerID
Oct 4, 2025
Merged

webdriver: Implement Pointer ID#39642
yezhizhen merged 2 commits intoservo:mainfrom
yezhizhen:add-pointerID

Conversation

@yezhizhen
Copy link
Copy Markdown
Member

This is necessary first step to distinguish pointer sources: "mouse, pen, touch".

Spec: https://w3c.github.io/webdriver/#dfn-get-a-pointer-id.

Testing: No behaviour change yet as we still only dispatch pointer type: mouse.
Fixes: Part of #39264.

Signed-off-by: Euclid Ye <[email protected]>
@yezhizhen yezhizhen requested review from jdm and xiaochengh October 3, 2025 03:52
@servo-highfive servo-highfive added the S-awaiting-review There is new code that needs to be reviewed. label Oct 3, 2025
}

/// <https://w3c.github.io/webdriver/#dfn-get-a-pointer-id>
pub(crate) fn get_pointer_id(subtype: PointerType, pointer_ids: FxHashSet<u32>) -> u32 {
Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Essentially mouse starts with 0, everything else starts with 2. New id to insert is the minimum possible one. But only god knows why it is designed like this.. This logic is not useful at all when multiple input sources are present....

@servo-highfive servo-highfive removed the S-awaiting-review There is new code that needs to be reviewed. label Oct 4, 2025
@yezhizhen yezhizhen added this pull request to the merge queue Oct 4, 2025
@servo-highfive servo-highfive added the S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. label Oct 4, 2025
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Oct 4, 2025
@servo-highfive servo-highfive added S-tests-failed The changes caused existing tests to fail. and removed S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. labels Oct 4, 2025
@yezhizhen yezhizhen added this pull request to the merge queue Oct 4, 2025
@servo-highfive servo-highfive added S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. and removed S-tests-failed The changes caused existing tests to fail. labels Oct 4, 2025
Merged via the queue into servo:main with commit 44d287c Oct 4, 2025
31 checks passed
@yezhizhen yezhizhen deleted the add-pointerID branch October 4, 2025 15:48
@servo-highfive servo-highfive removed the S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. label Oct 4, 2025
WaterWhisperer added a commit to WaterWhisperer/servo that referenced this pull request Oct 5, 2025
{"fail_fast": false, "matrix": [{"name": "Linux (WPT)", "workflow": "linux", "wpt": true, "profile": "release", "unit_tests": false, "build_libservo": false, "bencher": false, "build_args": "", "wpt_args": "", "number_of_wpt_chunks": 20}]}
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.

3 participants