void (CloseSearchTask caller, List<? extends SearchResult> allMatchesAtFrame, int indexOfClosestResult) { ApplicationManager.getApplication().invokeLater(() -> { if (!caller.isShouldStop()) { setNewStatusText(""); SearchResult closestResult = allMatchesAtFrame.get(indexOfClosestResult); largeFileEditor.getEditorModel().showSearchResult(closestResult); largeFileEditor.getEditorModel().setHighlightingCloseSearchResultsEnabled(true); } }); }