Merged
Conversation
Contributor
Author
|
Do I have to do something to get a reviewer? What does it mean that it has been assigned to me? |
This fixes two issues: 1. Occasionally the mouse hit test will find a gap between characters and `request.target` will be `div.overflow-guard`. This causes a different code path to be followed and the snapping code is not called. I fixed that by moving the snapping code to the outermost function so it is always called. 2. `request.mouseContentHorizontalOffset` is a float but `createMouseTargetFromHitTestPosition` treats it as an int. I initially thought this was the cause of the broken sticky tabs. I don't think it actually was but it seems like a good idea to fix anyway. I also slightly simplified the control flow in `mouseContentHorizontalOffset`. Fixes microsoft#155299
f6da31e to
0ab9506
Compare
Member
|
Thank you! |
Contributor
Author
|
Np, thanks for the review! |
This file contains hidden or 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
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
This fixes two issues:
request.targetwill bediv.overflow-guard. This causes a different code path to be followed and the snapping code is not called. I fixed that by moving the snapping code to the outermost function so it is always called.request.mouseContentHorizontalOffsetis a float butcreateMouseTargetFromHitTestPositiontreats it as an int. I initially thought this was the cause of the broken sticky tabs. I don't think it actually was but it seems like a good idea to fix anyway.I also slightly simplified the control flow in
mouseContentHorizontalOffset.Fixes #155299
Easiest way to test is to create a text file with a load of random spaces and hard tabs. Zoom VSCode in loads. Then make lots of clicks and selections with the mouse, and move the cursor around with the keyboard. Use multiple cursors etc. Make sure it all looks good. Make some mouse selections by dragging slowly, since there can be errors that only happen at a single pixel.
You guys don't do any GUI end to end testing as far as I can tell (fair enough; it's a right pain) so I think manual testing is the only option.