private void restartMergeResolveIfNeeded() {
    if (isDisposed()) return;
    if (myTextDiffProvider.getIgnorePolicy().equals(myCurrentIgnorePolicy) &&
        getTextSettings().isAutoResolveImportConflicts() == myResolveImportConflicts) {
      return;
    }

    if (!myInitialRediffFinished) {
      ApplicationManager.getApplication().invokeLater(() -> restartMergeResolveIfNeeded());
      return;
    }

    if (myContentModified) {
      if (Messages.showYesNoDialog(myProject,
                                   DiffBundle.message("changing.highlighting.requires.the.file.merge.restart"),
                                   DiffBundle.message("update.highlighting.settings"),
                                   DiffBundle.message("discard.changes.and.restart.merge"),
                                   DiffBundle.message("continue.merge"),
                                   Messages.getQuestionIcon()) != Messages.YES) {
        getTextSettings().setIgnorePolicy(myCurrentIgnorePolicy);
        getTextSettings().setAutoResolveImportConflicts(myResolveImportConflicts);
        return;
      }
    }

    myInitialRediffFinished = false;
    doRediff();
  }
private void restartMergeResolveIfNeeded()