void (CaretEvent e) { if (myCloseSearchResultsList.getSelectedIndex() != -1 && e.getEditor().getCaretModel().getOffset() != myCloseSearchResultsList.getSelectedValue().startPosition.symbolOffsetInPage && e.getEditor().getCaretModel().getOffset() != 0) { myCloseSearchResultsList.clearSelection(); } }