FileHistoryUi (@NotNull Project project, @NotNull VcsLogData logData) { FileHistoryUiProperties properties = project.getService(FileHistoryUiProperties.class); VcsLogFilterCollection filters = FileHistoryFilterer.createFilters(myFilePath, myHash, myRoot, properties.get(FileHistoryUiProperties.SHOW_ALL_BRANCHES)); String logId = FileHistoryUi.getFileHistoryLogId(myFilePath, myHash); FileHistoryFilterer filterer = new FileHistoryFilterer(logData, logId); VisiblePackRefresherImpl visiblePackRefresher = new VisiblePackRefresherImpl(project, logData, filters, PermanentGraph.SortType.Normal, filterer, logId) { @Override public void dispose() { super.dispose(); Disposer.dispose(filterer); // disposing filterer after the refresher } }; FileHistoryUi ui = new FileHistoryUi(logData, properties, visiblePackRefresher, myFilePath, myHash, myRoot, logId, Objects.requireNonNull(logData.getLogProvider(myRoot).getDiffHandler())); RegistryValueListener registryValueListener = new RegistryValueListener() { @Override public void afterValueChanged(@NotNull RegistryValue value) { visiblePackRefresher.onRefresh(); } }; FileHistoryBuilder.refineValue.addListener(registryValueListener, ui); FileHistoryBuilder.removeTrivialMergesValue.addListener(registryValueListener, ui); return ui; }