src/vs/workbench/contrib/terminal/browser/terminalTabbedView.ts/TerminalTabbedView/_openContextMenu
class TerminalTabbedView:	private _openContextMenu(event: MouseEvent, parent: HTMLElement): void {
		const standardEvent = new StandardMouseEvent(event);

		const anchor: { x: number, y: number } = { x: standardEvent.posx, y: standardEvent.posy };
		const actions: IAction[] = [];
		let menu: IMenu;
		if (parent === this._terminalContainer) {
			menu = this._instanceMenu;
		} else {
			menu = this._tabList.getFocus().length === 0 ? this._tabsListEmptyMenu : this._tabsListMenu;
		}

		const actionsDisposable = createAndFillInContextMenuActions(menu, undefined, actions);

		// TODO: Convert to command?
		if (menu === this._tabsListEmptyMenu) {
			actions.push(...this._getTabActions());
		}

		this._contextMenuService.showContextMenu({
			getAnchor: () => anchor,
			getActions: () => actions,
			getActionsContext: () => this._parentElement,
			onHide: () => actionsDisposable.dispose()
		});
	}