forked from jsdom/jsdom
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
MouseEvent: fix
pageX/Y
during dispatch
Ensure that they correctly reflect the coordinate relative to the origin of the window at the time of init (i.e. `clientX/Y` plus `scrollX/Y`). We record it during init, since during scrollX/Y may have change and result in the wrong `pageX/Y` values; see added tuWPT. Also track the target-relative coordinate during init (still just `(0, 0)` in the absence of layout support). This doesn't fundamentally change any behavior, but makes the implementation more future proof, making it safer to start handling Image Button submitters when constructing the form data set; see jsdom#3496 where this code was extracted from.
- Loading branch information
Showing
2 changed files
with
34 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters