boolean (@NotNull Object selected, int modifiers, @NotNull String searchText) { if (selected instanceof PsiElement) { if (!((PsiElement)selected).isValid()) { LOG.warn("Cannot navigate to invalid PsiElement"); return true; } ReadAction.nonBlocking(() -> { PsiElement psiElement = preparePsi((PsiElement)selected, modifiers, searchText); Navigatable extNavigatable = createExtendedNavigatable(psiElement, searchText, modifiers); VirtualFile file = PsiUtilCore.getVirtualFile(psiElement); Runnable command = (modifiers & InputEvent.SHIFT_MASK) != 0 && file != null ? () -> OpenInRightSplitAction.Companion.openInRightSplit(myProject, file, extNavigatable, true) : () -> doNavigate(psiElement, extNavigatable); return command; }) .finishOnUiThread(ModalityState.nonModal(), Runnable::run) .submit(AppExecutorUtil.getAppExecutorService()); } else { EditSourceUtil.navigate(((NavigationItem)selected), true, false); } return true; }