MCPcopy Create free account
hub / github.com/sql-js/sql.js / operation

Function operation

GUI/codemirror/lib/codemirror.js:1977–1984  ·  view source on GitHub ↗
(cm, f)

Source from the content-addressed store, hash-verified

1975 }
1976 // Wraps a function in an operation. Returns the wrapped function.
1977 function operation(cm, f) {
1978 return function() {
1979 if (cm.curOp) return f.apply(cm, arguments);
1980 startOperation(cm);
1981 try { return f.apply(cm, arguments); }
1982 finally { endOperation(cm); }
1983 };
1984 }
1985 // Used to add methods to editor and doc instances, wrapping them in
1986 // operations.
1987 function methodOp(f) {

Callers 12

barMouseDownFunction · 0.85
registerEventHandlersFunction · 0.85
leftButtonStartDragFunction · 0.85
extendFunction · 0.85
leftButtonSelectFunction · 0.85
loadFileFunction · 0.85
onContextMenuFunction · 0.85
pollFunction · 0.85
makeChangeFunction · 0.85
makeChangeSingleDocFunction · 0.85
codemirror.jsFile · 0.85
markTextFunction · 0.85

Calls 2

startOperationFunction · 0.85
endOperationFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…