private void runWithProgress(@NotNull Runnable action) {
    if (myWithModalProgress) {
      ProgressManager.getInstance().runProcessWithProgressSynchronously(action, title, true, myProject);
    }
    else {
      ApplicationManager.getApplication().assertIsNonDispatchThread();
      action.run();
    }
  }
private void runWithProgress(@NotNull Runnable action)