Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.
Sign upImplement PointerEvents #16105
Implement PointerEvents #16105
Comments
|
@ferjm I am interested in taking this. Any starting tips? |
|
Hello @dowoncha! Thank you for your interest on taking this task. I myself am starting with Servo, so apologies in advance if my tips are not accurate enough. I am CCing @jdm and @mbrubeck who know way more than me about this stuff. First of all, this work involves touching several pieces of Servo, so in case that you haven't already done it, it would be good to read the Design notes. I saw that you already contributed some code to Servo \o/, so I won't mention any specifics about the contribution process, but feel free to ask any question about it. I would also recommend reading @jeenalee 's blog post about how to implement a new DOM API for Servo, as it covers some of the work required here. In essence, you will need to create a new According to the spec, you'll need to extend @jdm and @mbrubeck can correct me if I am wrong, but I believe for mouse events everything starts in Glutin, which is the cross-platform windowing and input lib used in Servo. It seems to support mouse and touch devices but it may need to be extended with pen/tablet input support. I would recommend leaving this work for later. Glutin events are handled here by Servo's glutin app, which dispatches the events to the compositor. The Compositor sends a ConstellationControlMsg::SendEvent message with the Pipeline ID and the details of the mouse event. This message is handled by the script thread which ends up calling document.handle_mouse_event. There is where the creation and dispatch of the DOM MouseEvent happens. I hope I gave you enough to start. Please, let me know if you have any specific question. Feel free to ping me on IRC as well (:ferjm there). Thank you again for your interest in taking this work. Happy hacking! |
|
The PointerEvent webidl has certain attributes with type long. I expected those to correspond to an I noticed some dom structures such as |
|
The types that the generated bindings provide are correct. |
|
I am now ready to implement the trait items (e.g. |
|
They should be part of the |
|
cc @jdm I would like to submit a WIP PR, could you open up a pointerevent branch on servo/servo |
|
@highfive: assign me |
|
Hey @dowoncha! Thanks for your interest in working on this issue. It's now assigned to you! |
|
Opening up a WIP PR is fine; there's no need to have a branch on servo/servo for that. |
|
WIP PR #16273 |
Spec: https://www.w3.org/TR/pointerevents/