MCPcopy
hub / github.com/wavetermdev/waveterm / showContextMenu

Method showContextMenu

frontend/app/store/contextmenu.ts:71–87  ·  view source on GitHub ↗
(menu: ContextMenuItem[], ev: React.MouseEvent<any>, opts?: ShowContextMenuOpts)

Source from the content-addressed store, hash-verified

69 }
70
71 showContextMenu(menu: ContextMenuItem[], ev: React.MouseEvent<any>, opts?: ShowContextMenuOpts): void {
72 ev.stopPropagation();
73 this.handlers.clear();
74 this.activeOpts = opts;
75 const electronMenuItems = this._convertAndRegisterMenu(menu);
76
77 const workspaceId = globalStore.get(atoms.workspaceId);
78 let oid: string;
79
80 if (workspaceId != null) {
81 oid = workspaceId;
82 } else {
83 oid = globalStore.get(atoms.builderId);
84 }
85
86 getApi().showContextMenu(oid, electronMenuItems);
87 }
88}
89
90export { ContextMenuModel };

Callers 15

handleContextMenuFunction · 0.80
makeWaveEnvImplFunction · 0.80
handleWaveAIContextMenuFunction · 0.80
processviewer.tsxFile · 0.80
TerminalViewFunction · 0.80
TableBodyFunction · 0.80
DirectoryPreviewFunction · 0.80
constructorMethod · 0.80
tab.tsxFile · 0.80
VTabWrapperFunction · 0.80

Calls 4

getApiFunction · 0.90
clearMethod · 0.80
getMethod · 0.80

Tested by

no test coverage detected