void (final Project project, final Task task) { JBPopup hint = DocumentationManager.getInstance(project).getDocInfoHint(); if (hint != null) hint.cancel(); ApplicationManager.getApplication().invokeLater(() -> new OpenTaskDialog(project, task).show()); }