@Override
  protected Action @NotNull [] createActions() {
    var canRestart = ApplicationManager.getApplication().isRestartCapable();
    mySaveAndExitAction = new DialogWrapperAction(DiagnosticBundle.message(canRestart ? "change.memory.apply" : "change.memory.exit")) {
      @Override
      protected void doAction(ActionEvent e) {
        if (save()) {
          ((ApplicationEx)ApplicationManager.getApplication()).restart(true);
        }
      }
    };
    mySaveAction = new DialogWrapperAction(IdeBundle.message("button.save")) {
      @Override
      protected void doAction(ActionEvent e) {
        if (save()) {
          close(OK_EXIT_CODE);
        }
      }
    };
    return new Action[]{mySaveAndExitAction, mySaveAction, getCancelAction()};
  }
@Override
  protected Action @NotNull [] createActions()