MCPcopy Create free account
hub / github.com/breck7/scroll / onContextMenu

Function onContextMenu

external/.scrollLibs.js:10435–10445  ·  view source on GitHub ↗
(cm, e)

Source from the content-addressed store, hash-verified

10433 // textarea (making it as unobtrusive as possible) to let the
10434 // right-click take effect on it.
10435 function onContextMenu(cm, e) {
10436 if (eventInWidget(cm.display, e) || contextMenuInGutter(cm, e)) {
10437 return
10438 }
10439 if (signalDOMEvent(cm, e, "contextmenu")) {
10440 return
10441 }
10442 if (!captureRightClick) {
10443 cm.display.input.onContextMenu(e)
10444 }
10445 }
10446
10447 function contextMenuInGutter(cm, e) {
10448 if (!hasHandler(cm, "gutterContextMenu")) {

Callers 1

registerEventHandlersFunction · 0.85

Calls 3

eventInWidgetFunction · 0.85
contextMenuInGutterFunction · 0.85
signalDOMEventFunction · 0.85

Tested by

no test coverage detected