ExtendableTextField (@NotNull Runnable action, @Nullable Disposable parentDisposable) { KeyStroke keyStroke = KeyStroke.getKeyStroke(KeyEvent.VK_ENTER, InputEvent.SHIFT_DOWN_MASK); String tooltip = UIBundle.message("component.with.browse.button.browse.button.tooltip.text") + " (" + KeymapUtil.getKeystrokeText(keyStroke) + ")"; ExtendableTextComponent.Extension browseExtension = ExtendableTextComponent.Extension.create(AllIcons.General.OpenDisk, AllIcons.General.OpenDiskHover, tooltip, action); new DumbAwareAction() { @Override public void actionPerformed(@NotNull AnActionEvent e) { action.run(); } }.registerCustomShortcutSet(new CustomShortcutSet(keyStroke), this, parentDisposable); addExtension(browseExtension); return this; }