void (@NotNull AnActionEvent e) { ServiceView selectedView = getSelectedView(e); if (selectedView == null) return; if (getSelectedItems(e).size() == 1) { AnAction[] children = getChildren(e); for (AnAction child : children) { if (child instanceof OpenInNewTabAction) { ActionUtil.performActionDumbAwareWithCallbacks(child, e); return; } } } ListPopup popup = JBPopupFactory.getInstance().createActionGroupPopup(null, this, e.getDataContext(), true, null, 5); popup.setAdText(ExecutionBundle.message("service.view.open.in.new.tab.ad.text"), SwingConstants.LEFT); if (e.isFromActionToolbar()) { Component source = ObjectUtils.tryCast(e.getInputEvent().getSource(), Component.class); if (source != null) { popup.showUnderneathOf(source); return; } } popup.showInBestPositionFor(e.getDataContext()); }