@Override
  public void actionPerformed(@NotNull AnActionEvent e) {
    Project project = e.getProject();
    History history = e.getData(History.KEY);

    if (history != null) {
      history.forward();
    }
    else if (project != null) {
      IdeDocumentHistory.getInstance(project).forward();
    }
  }
@Override
  public void actionPerformed(@NotNull AnActionEvent e)