idea-plugin / arrow.meta.ide.dsl.ui.toolwindow / ToolWindowSyntax / addToolWindowNotification

addToolWindowNotification

open fun IdeMetaPlugin.addToolWindowNotification(toolId: String, actionId: String, type: MessageType, html: String, icon: Icon? = null, listener: (HyperlinkEvent) -> Unit = Noop.effect1, update: (AnActionEvent) -> Unit = Noop.effect1): ExtensionPhase

Adds a notification balloon to the Toolwindow and only disappears if the users clicks on it.

import arrow.meta.ide.IdePlugin
import arrow.meta.ide.IdeMetaPlugin
import arrow.meta.ide.resources.ArrowIcons
import arrow.meta.ide.invoke
import com.intellij.openapi.ui.MessageType
import com.intellij.openapi.wm.ToolWindowId

val IdeMetaPlugin.toolWindowBalloons: IdePlugin
  get() = "ToolWindowBalloon" {
    meta(
      addToolWindowNotification(
        ToolWindowId.PROJECT_VIEW,
        "Unique",
        MessageType.INFO,
        "Teach your users about this tool window",
        ArrowIcons.ICON2
      )
    )
  }

See Also

toolWindowNotification

Do you like Arrow?

Arrow Org
<