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

Function on

tools/pythonauto/static/codemirror/codemirror.js:5500–5510  ·  view source on GitHub ↗
(emitter, type, f)

Source from the content-addressed store, hash-verified

5498 // EVENT HANDLING
5499
5500 function on(emitter, type, f) {
5501 if (emitter.addEventListener)
5502 emitter.addEventListener(type, f, false);
5503 else if (emitter.attachEvent)
5504 emitter.attachEvent("on" + type, f);
5505 else {
5506 var map = emitter._handlers || (emitter._handlers = {});
5507 var arr = map[type] || (map[type] = []);
5508 arr.push(f);
5509 }
5510 }
5511
5512 function off(emitter, type, f) {
5513 if (emitter.removeEventListener)

Callers 15

updateScrollbarsFunction · 0.85
registerEventHandlersFunction · 0.85
leftButtonStartDragFunction · 0.85
leftButtonSelectFunction · 0.85
showCrossHairFunction · 0.85
onContextMenuFunction · 0.85
codemirror.jsFile · 0.85
markTextFunction · 0.85
eventMixinFunction · 0.85
registerEventHandlersFunction · 0.85
onMouseDownFunction · 0.85
onContextMenuFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected