void (@NotNull Project project, @NotNull String operationName, @NotNull List<? extends Change> changes, @NotNull Collection<String> absolutePaths) { String title = GitBundle.message("dialog.title.local.changes.prevent.from.operation", StringUtil.capitalize(operationName)); String description = getErrorDialogDescription(); if (changes.isEmpty()) { GitUtil.showPathsInDialog(project, absolutePaths, title, description); } else { ChangesBrowserWithRollback changesViewer = new ChangesBrowserWithRollback(project, changes); DialogBuilder builder = new DialogBuilder(project); builder.setNorthPanel(new MultiLineLabel(description)); builder.setCenterPanel(changesViewer); builder.addDisposable(changesViewer); builder.addOkAction(); builder.setTitle(title); builder.show(); } }