MCPcopy Index your code
hub / github.com/DHTMLX/gantt / historyChangeFromChange

Function historyChangeFromChange

samples/common/codehighlight/codemirror.js:4821–4826  ·  view source on GitHub ↗
(doc, change)

Source from the content-addressed store, hash-verified

4819 // Create a history change event from an updateDoc-style change
4820 // object.
4821 function historyChangeFromChange(doc, change) {
4822 var histChange = {from: copyPos(change.from), to: changeEnd(change), text: getBetween(doc, change.from, change.to)};
4823 attachLocalSpans(doc, histChange, change.from.line, change.to.line + 1);
4824 linkedDocs(doc, function (doc) { return attachLocalSpans(doc, histChange, change.from.line, change.to.line + 1); }, true);
4825 return histChange
4826 }
4827
4828 // Pop all selection events off the end of a history array. Stop at
4829 // a change event.

Callers 2

addChangeToHistoryFunction · 0.85
loopFunction · 0.85

Calls 5

copyPosFunction · 0.85
changeEndFunction · 0.85
getBetweenFunction · 0.85
attachLocalSpansFunction · 0.85
linkedDocsFunction · 0.85

Tested by

no test coverage detected