platform: show / hide buttons is a part of the renderer

This commit is contained in:
anstarovoyt
2018-06-09 13:44:58 +03:00
parent 5f5ad9b647
commit 8a08eb919e
3 changed files with 4 additions and 4 deletions
@@ -23,7 +23,7 @@ class DaemonTooltipActionProvider : TooltipActionProvider {
}
class DaemonTooltipAction(private val myFixText: String, private val myActualOffset: Int) : TooltipAction {
override fun getText(): String {
return myFixText
}
@@ -104,7 +104,9 @@ internal class DaemonTooltipWithActionRenderer(text: String?,
JBUI.insets(3, 3, 0, 3), 0, 0)
grid.add(settingsComponent, settingsConstraints)
addActionsRow(hintHint, hint, editor, actions, grid)
if (isShowActions()) {
addActionsRow(hintHint, hint, editor, actions, grid)
}
}
private fun addActionsRow(hintHint: HintHint,
@@ -27,8 +27,6 @@ public interface TooltipActionProvider {
@Nullable
static TooltipAction calcTooltipAction(@NotNull final HighlightInfo info, @NotNull Editor editor) {
if (!isShowActions()) return null;
for (TooltipActionProvider extension : EXTENSION_POINT_NAME.getExtensions()) {
TooltipAction action = extension.getTooltipAction(info, editor);
if (action != null) return action;