void (@NotNull AnActionEvent e) { EditorSearchSession search = e.getRequiredData(EditorSearchSession.SESSION_KEY); FindModel findModel = search.getFindModel(); if (!findModel.isReplaceState()) { findModel.setReplaceState(true); } search.getComponent().getSearchTextComponent().selectAll(); }