ProgressWindow (@NotNull @NlsContexts.ProgressTitle String progressTitle, boolean canBeCanceled, boolean shouldShowModalWindow, @Nullable Project project, @Nullable JComponent parentComponent, @Nullable @NlsContexts.Button String cancelText) { ProgressWindow progress = new ProgressWindow(canBeCanceled, !shouldShowModalWindow, project, parentComponent, cancelText); // in case of abrupt application exit when 'ProgressManager.getInstance().runProcess(process, progress)' below // does not have a chance to run, and as a result the progress won't be disposed Disposer.register(this, progress); progress.setTitle(progressTitle); return progress; }