void (@NotNull AnActionEvent e) { final Presentation presentation = e.getPresentation(); if (myViewMap.size() <= 1) { presentation.setEnabledAndVisible(false); } else { presentation.setEnabledAndVisible(true); Toggleable.setSelected(presentation, isSelected(e)); } }