MCPcopy
hub / github.com/nwutils/nw-sample-apps / updateLine

Function updateLine

mini-code-edit/cm/lib/codemirror.js:760–760  ·  view source on GitHub ↗
(n)

Source from the content-addressed store, hash-verified

758
759 // Update the selection
760 function updateLine(n) {return n <= Math.min(to.line, to.line + lendiff) ? n : n + lendiff;}
761 setSelection(selFrom, selTo, updateLine(sel.from.line), updateLine(sel.to.line));
762
763 // Make sure the scroll-size div has the correct height.

Callers 1

updateLinesNoUndoFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected