MCPcopy
hub / github.com/witheve/Eve / startOperation

Function startOperation

src/codemirror.js:3010–3036  ·  view source on GitHub ↗
(cm)

Source from the content-addressed store, hash-verified

3008 var nextOpId = 0;
3009 // Start a new operation.
3010 function startOperation(cm) {
3011 cm.curOp = {
3012 cm: cm,
3013 viewChanged: false, // Flag that indicates that lines might need to be redrawn
3014 startHeight: cm.doc.height, // Used to detect need to update scrollbar
3015 forceUpdate: false, // Used to force a redraw
3016 updateInput: null, // Whether to reset the input textarea
3017 typing: false, // Whether this reset should be careful to leave existing text (for compositing)
3018 changeObjs: null, // Accumulated changes, for firing change events
3019 cursorActivityHandlers: null, // Set of handlers to fire cursorActivity on
3020 cursorActivityCalled: 0, // Tracks which cursorActivity handlers have been called already
3021 selectionChanged: false, // Whether the selection needs to be redrawn
3022 updateMaxLine: false, // Set when the widest line needs to be determined anew
3023 scrollLeft: null, scrollTop: null, // Intermediate scroll position, not pushed to DOM yet
3024 scrollToPos: null, // Used to scroll to a specific position
3025 focus: false,
3026 id: ++nextOpId // Unique ID
3027 };
3028 if (operationGroup) {
3029 operationGroup.ops.push(cm.curOp);
3030 } else {
3031 cm.curOp.ownsGroup = operationGroup = {
3032 ops: [cm.curOp],
3033 delayedCallbacks: []
3034 };
3035 }
3036 }
3037
3038 function fireCallbacksForOps(group) {
3039 // Calls delayed callbacks and cursorActivity handlers until no

Callers 6

CodeMirrorFunction · 0.85
runInOpFunction · 0.85
operationFunction · 0.85
methodOpFunction · 0.85
docMethodOpFunction · 0.85
codemirror.jsFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected