-
-
Notifications
You must be signed in to change notification settings - Fork 2.9k
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
Ensure mouse events are dispatched to document/window as necessary #6733
Comments
This is just https://dom.spec.whatwg.org/#concept-event-dispatch step 4 (which we implement) plus https://html.spec.whatwg.org/multipage/#events-and-the-window-object, which I've been meaning to file once we have better tests for it, right? |
Yep. |
Although I've been meaning to look into what other browsers do with mouse events that are not targeted at a particular child node of the body element - specifically, what if the mouse is being moved or clicked outside of the bounds of any page content, but inside the bounds of the enclosing frame? |
The root element covers the viewport. |
We also need that for the keyboard events. |
@paulrouget Could you file a separate issue for that? |
This is now self-contained in the DOM spec: |
The DOM specification says: A document's get the parent algorithm, given an event, returns null if event's type attribute value is "load" or document does not have a browsing context, and the document's associated Window object otherwise.
The DOM specification says: A document's get the parent algorithm, given an event, returns null if event's type attribute value is "load" or document does not have a browsing context, and the document's associated Window object otherwise.
The DOM specification says: A document's get the parent algorithm, given an event, returns null if event's type attribute value is "load" or document does not have a browsing context, and the document's associated Window object otherwise.
The DOM specification says: A document's get the parent algorithm, given an event, returns null if event's type attribute value is "load" or document does not have a browsing context, and the document's associated Window object otherwise.
Fix the "get the parent" loop when dispatching event (fixes #6733) The DOM specification says: > A document's get the parent algorithm, given an event, returns null > if event's type attribute value is "load" or document does not have > a browsing context, and the document's associated Window object > otherwise. <!-- Reviewable:start --> [<img src="https://reviewable.io/review_button.svg" height="40" alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9734) <!-- Reviewable:end -->
The DOM specification says: A document's get the parent algorithm, given an event, returns null if event's type attribute value is "load" or document does not have a browsing context, and the document's associated Window object otherwise.
Fix the "get the parent" loop when dispatching event (fixes #6733) The DOM specification says: > A document's get the parent algorithm, given an event, returns null > if event's type attribute value is "load" or document does not have > a browsing context, and the document's associated Window object > otherwise. <!-- Reviewable:start --> [<img src="https://reviewable.io/review_button.svg" height="40" alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9734) <!-- Reviewable:end -->
The DOM specification says: A document's get the parent algorithm, given an event, returns null if event's type attribute value is "load" or document does not have a browsing context, and the document's associated Window object otherwise.
The DOM specification says: A document's get the parent algorithm, given an event, returns null if event's type attribute value is "load" or document does not have a browsing context, and the document's associated Window object otherwise.
Fix the "get the parent" loop when dispatching event (fixes #6733) The DOM specification says: > A document's get the parent algorithm, given an event, returns null > if event's type attribute value is "load" or document does not have > a browsing context, and the document's associated Window object > otherwise. <!-- Reviewable:start --> [<img src="https://reviewable.io/review_button.svg" height="40" alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9734) <!-- Reviewable:end -->
Fix the "get the parent" loop when dispatching event (fixes #6733) The DOM specification says: > A document's get the parent algorithm, given an event, returns null > if event's type attribute value is "load" or document does not have > a browsing context, and the document's associated Window object > otherwise. <!-- Reviewable:start --> [<img src="https://reviewable.io/review_button.svg" height="40" alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9734) <!-- Reviewable:end -->
I'm not sure what the spec mandates here, but I'm pretty sure our implementation is lacking.
The text was updated successfully, but these errors were encountered: