update gutterOffsetX range (dirtydiff , fold) (#184339)

* update gutterOffsetX range (dirtydiff , fold)

* Update comment

---------

Co-authored-by: Alex Ross <alros@microsoft.com>
This commit is contained in:
xie jialong 努力鸭 2023-06-07 19:34:34 +08:00 committed by GitHub
parent bae0533322
commit 30092f40a3
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 2 deletions

View file

@ -413,7 +413,7 @@ export class FoldingController extends Disposable implements IEditorContribution
// const gutterOffsetX = data.offsetX - data.glyphMarginWidth - data.lineNumbersWidth - data.glyphMarginLeft;
// TODO@joao TODO@alex TODO@martin this is such that we don't collide with dirty diff
if (gutterOffsetX < 5) { // the whitespace between the border and the real folding icon border is 5px
if (gutterOffsetX < 4) { // the whitespace between the border and the real folding icon border is 4px
return;
}

View file

@ -922,7 +922,7 @@ export class DirtyDiffController extends Disposable implements DirtyDiffContribu
const gutterOffsetX = data.offsetX - offsetLeftInGutter;
// TODO@joao TODO@alex TODO@martin this is such that we don't collide with folding
if (gutterOffsetX < -3 || gutterOffsetX > 6) { // dirty diff decoration on hover is 9px wide
if (gutterOffsetX < -3 || gutterOffsetX > 3) { // dirty diff decoration on hover is 6px wide
return;
}