Report click event modifiers from both mousedown and mouseup #39707
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Closes #12752
Closes #16074
Closes #17892
Some input devices report very delayed mouseup events, which can cause mouseup -> control to be reported as mouseup+control, causing frustrating behavior during common editing actions, like moving the cursor into a word with the mouse and then quickly triggering a keyboard shortcut.
Note that although web browsers largely seem to reflect modifiers from only mouseup events on their corresponding click events, text editors (e.g. VS Code) only respond to modifiers that were held during both mousedown and mouseup events.
These were all marked as closed by #22988. This fix was reverted by #35075, which attempted to align behavior more closely with browser behavior. As can be seen by the additional comments on #12752, this has caused a frustrating regression in user experience for at least some input devices.
Release Notes: