void (@NotNull JPanel toolBarPanel) { mySearchTextArea = new SearchTextArea(new JTextArea(), true); mySearchTextArea.setBorder(IdeBorderFactory.createBorder(SideBorder.LEFT | SideBorder.TOP | SideBorder.RIGHT)); new NextOccurenceAction(true).registerCustomShortcutSet(Utils.shortcutSetOf(ContainerUtil.concat( Utils.shortcutsOf(IdeActions.ACTION_FIND_NEXT), Utils.shortcutsOf(IdeActions.ACTION_EDITOR_MOVE_CARET_DOWN) )), mySearchTextArea); new NextOccurenceAction(false).registerCustomShortcutSet(Utils.shortcutSetOf(ContainerUtil.concat( Utils.shortcutsOf(IdeActions.ACTION_FIND_PREVIOUS), Utils.shortcutsOf(IdeActions.ACTION_EDITOR_MOVE_CARET_UP) )), mySearchTextArea); new DumbAwareAction() { @Override public void actionPerformed(@NotNull AnActionEvent e) { IdeFocusManager.getInstance(myProject).requestFocus(mySearchTextArea.getTextArea(), true); } }.registerCustomShortcutSet(Utils.shortcutSetOf(Utils.shortcutsOf(IdeActions.ACTION_FIND)), myRevisionsList.getComponent()); new DumbAwareAction() { @Override public void actionPerformed(@NotNull AnActionEvent e) { mySearchTextArea.getTextArea().setText(""); IdeFocusManager.getInstance(myProject).requestFocus(myRevisionsList.getComponent(), true); } }.registerCustomShortcutSet(new CustomShortcutSet(KeyEvent.VK_ESCAPE), mySearchTextArea.getTextArea()); LoadingDecorator decorator = new ProgressBarLoadingDecorator(mySearchTextArea, this, 500) { @Override protected boolean isOnTop() { return false; } }; mySearchTextArea.getTextArea().getDocument().addDocumentListener(new DocumentAdapter() { @Override protected void textChanged(@NotNull DocumentEvent e) { myAlarm.cancelAllRequests(); myAlarm.addRequest(() -> applyFilterText(StringUtil.nullize(mySearchTextArea.getTextArea().getText()), decorator), 100); } }); toolBarPanel.add(decorator.getComponent(), BorderLayout.CENTER); }