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

Function forEachCodeMirror

samples/common/codehighlight/codemirror.js:6607–6617  ·  view source on GitHub ↗
(f)

Source from the content-addressed store, hash-verified

6605 // garbage collected.
6606
6607 function forEachCodeMirror(f) {
6608 if (!document.getElementsByClassName) { return }
6609 var byClass = document.getElementsByClassName("CodeMirror"), editors = [];
6610 for (var i = 0; i < byClass.length; i++) {
6611 var cm = byClass[i].CodeMirror;
6612 if (cm) { editors.push(cm); }
6613 }
6614 if (editors.length) { editors[0].operation(function () {
6615 for (var i = 0; i < editors.length; i++) { f(editors[i]); }
6616 }); }
6617 }
6618
6619 var globalsRegistered = false;
6620 function ensureGlobalHandlers() {

Callers 1

registerGlobalHandlersFunction · 0.85

Calls 1

fFunction · 0.85

Tested by

no test coverage detected