MCPcopy Index your code
hub / github.com/witheve/Eve / scrollIntoView

Function scrollIntoView

src/codemirror.js:4650–4654  ·  view source on GitHub ↗
(cm, x1, y1, x2, y2)

Source from the content-addressed store, hash-verified

4648
4649 // Scroll a given set of coordinates into view (immediately).
4650 function scrollIntoView(cm, x1, y1, x2, y2) {
4651 var scrollPos = calculateScrollPos(cm, x1, y1, x2, y2);
4652 if (scrollPos.scrollTop != null) setScrollTop(cm, scrollPos.scrollTop);
4653 if (scrollPos.scrollLeft != null) setScrollLeft(cm, scrollPos.scrollLeft);
4654 }
4655
4656 // Calculate a new scroll position needed to scroll the given
4657 // rectangle into view. Returns an object with scrollTop and

Callers 1

codemirror.jsFile · 0.85

Calls 3

calculateScrollPosFunction · 0.85
setScrollTopFunction · 0.85
setScrollLeftFunction · 0.85

Tested by

no test coverage detected