void (@NotNull VcsLogUi ui, @NotNull Runnable runnable, @NotNull Condition<? super VcsLogDataPack> condition) { ui.addLogListener(new VcsLogListener() { @Override public void onChange(@NotNull VcsLogDataPack dataPack, boolean refreshHappened) { if (condition.value(dataPack)) { runnable.run(); ui.removeLogListener(this); } } }); }