@Override
  public void update(@NotNull AnActionEvent event){
    Project project = event.getProject();
    Editor editor = event.getData(CommonDataKeys.EDITOR);
    boolean enabled = project != null && editor != null &&
                      !ActionGroupUtil.isGroupEmpty(getGroup(), event);
    if (ActionPlaces.isPopupPlace(event.getPlace())) {
      event.getPresentation().setEnabledAndVisible(enabled);
    }
    else {
      event.getPresentation().setEnabled(enabled);
    }
  }
@Override
  public void update(@NotNull AnActionEvent event)