void (@NotNull ProgressIndicator indicator) { // confirm removal from the VCS if needed if (myRemoveOption.getValue() != VcsShowConfirmationOption.Value.DO_NOTHING_SILENTLY) { if (myRemoveOption.getValue() == VcsShowConfirmationOption.Value.DO_ACTION_SILENTLY || filesToConfirmDeletion.isEmpty()) { filesToDelete.addAll(filesToConfirmDeletion); } else { final AtomicReference<Collection<FilePath>> filePaths = new AtomicReference<>(); ApplicationManager.getApplication().invokeAndWait(() -> filePaths.set(selectFilePathsToDelete(filesToConfirmDeletion))); if (filePaths.get() != null) { filesToDelete.addAll(filePaths.get()); } } } if (!filesToDelete.isEmpty()) { performDeletion(filesToDelete); } }