void (final SelectInContext context, boolean requestFocus) { Runnable r = () -> MavenProjectsNavigator.getInstance(context.getProject()).selectInTree(getMavenProject(context)); if (requestFocus) { ToolWindowManager.getInstance(context.getProject()).getToolWindow(getToolWindowId()).activate(r); } else { r.run(); } }