@Override
  protected @Nullable Presentation getPresentation(@NotNull ActionContext context, @NotNull PsiClass aClass) {
    PsiDirectory dir = context.file().getContainingDirectory();
    if (dir == null) return null;
    try {
      JavaDirectoryServiceImpl.checkCreateClassOrInterface(dir, aClass.getName());
    }
    catch (IncorrectOperationException e) {
      return null;
    }

    return Presentation.of(QuickFixBundle.message("move.class.to.separate.file.text", aClass.getName()));
  }
@Override
  protected @Nullable Presentation getPresentation(@NotNull ActionContext context, @NotNull PsiClass aClass)