void (FindModel findModel1) { if (myReentrantLock) return; try { myReentrantLock = true; if (myIsGlobal != myFindModel.isGlobal() || myIsReplace != myFindModel.isReplaceState()) { if (myFindModel.getStringToFind().isEmpty() && myFindModel.isGlobal()) { myFindModel.setStringToFind(StringUtil.notNullize(myEditor.getSelectionModel().getSelectedText())); } if (!myFindModel.isGlobal()) { if (myFindModel.getStringToFind().equals(myStartSelectedText)) { myFindModel.setStringToFind(""); } else { restoreInitialCaretPositionAndSelection(); } } myIsGlobal = myFindModel.isGlobal(); myIsReplace = myFindModel.isReplaceState(); } EditorSearchSession.this.updateUIWithFindModel(); mySearchResults.clear(); EditorSearchSession.this.updateResults(true); FindUtil.updateFindInFileModel(EditorSearchSession.this.getProject(), myFindModel, !ConsoleViewUtil.isConsoleViewEditor(editor)); } finally { myReentrantLock = false; } }