MCPcopy Index your code
hub / github.com/csev/py4e / updateLineForChanges

Function updateLineForChanges

tools/pythonauto/static/codemirrorepl/codemirror.js:755–764  ·  view source on GitHub ↗
(cm, lineView, lineN, dims)

Source from the content-addressed store, hash-verified

753 // lineView.changes. This updates the relevant part of the line's
754 // DOM structure.
755 function updateLineForChanges(cm, lineView, lineN, dims) {
756 for (var j = 0; j < lineView.changes.length; j++) {
757 var type = lineView.changes[j];
758 if (type == "text") updateLineText(cm, lineView);
759 else if (type == "gutter") updateLineGutter(cm, lineView, lineN, dims);
760 else if (type == "class") updateLineClasses(lineView);
761 else if (type == "widget") updateLineWidgets(lineView, dims);
762 }
763 lineView.changes = null;
764 }
765
766 // Lines with gutter elements, widgets or a background class need to
767 // be wrapped, and have the extra elements added to the wrapper div

Callers 2

patchDisplayFunction · 0.85
prepareMeasureForLineFunction · 0.85

Calls 4

updateLineTextFunction · 0.85
updateLineGutterFunction · 0.85
updateLineClassesFunction · 0.85
updateLineWidgetsFunction · 0.85

Tested by

no test coverage detected