fix scrolling over linter issues in usercss mode
This commit is contained in:
parent
c1dd196acd
commit
a66c377d8a
|
@ -333,11 +333,13 @@ function createSourceEditor(style) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function headerOnScroll({deltaY, deltaMode, shiftKey}) {
|
function headerOnScroll({target, deltaY, deltaMode, shiftKey}) {
|
||||||
if (deltaY < 0 && this.scrollTop ||
|
while ((target = target.parentElement)) {
|
||||||
deltaY > 0 && this.scrollTop + this.clientHeight < this.scrollHeight) {
|
if (deltaY < 0 && target.scrollTop ||
|
||||||
|
deltaY > 0 && target.scrollTop + target.clientHeight < target.scrollHeight) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
cm.display.scroller.scrollTop +=
|
cm.display.scroller.scrollTop +=
|
||||||
// WheelEvent.DOM_DELTA_LINE
|
// WheelEvent.DOM_DELTA_LINE
|
||||||
deltaMode === 1 ? deltaY * cm.display.cachedTextHeight :
|
deltaMode === 1 ? deltaY * cm.display.cachedTextHeight :
|
||||||
|
|
Loading…
Reference in New Issue
Block a user