Interface MessageDialogFacet

All Superinterfaces:
Facet
All Known Implementing Classes:
MessageDialogFacetImpl

@StudioFacet(xmlElement="messageDialog", caption="MessageDialog", description="Prepares and shows message dialogs", defaultProperty="message", category="Facets", icon="io/jmix/ui/icon/facet/dialog.svg", documentationURL="https://docs.jmix.io/jmix/%VERSION%/ui/facets/message-dialog-facet.html") public interface MessageDialogFacet extends Facet
Prepares and shows message dialogs.
  • Method Details

    • setCaption

      @StudioProperty(type=LOCALIZED_STRING) void setCaption(@Nullable String caption)
      Sets dialog caption.
      Parameters:
      caption - caption
    • getCaption

      @Nullable String getCaption()
      Returns:
      dialog caption
    • setMessage

      @StudioProperty(type=LOCALIZED_STRING) void setMessage(@Nullable String message)
      Sets dialog message.
      Parameters:
      message - message
    • getMessage

      @Nullable String getMessage()
      Returns:
      dialog message
    • setContentMode

      @StudioProperty(type=ENUMERATION, defaultValue="TEXT") void setContentMode(ContentMode contentMode)
      Sets dialog message content mode.
      Parameters:
      contentMode - content mode
    • getContentMode

      ContentMode getContentMode()
      Returns:
      dialog message content mode
    • setWindowMode

      @StudioProperty(type=ENUMERATION, defaultValue="NORMAL") void setWindowMode(WindowMode windowMode)
      Sets the mode of the dialog window
      Parameters:
      windowMode - the mode of the dialog window
    • getWindowMode

      WindowMode getWindowMode()
      Returns:
      the mode of the dialog window
    • setModal

      @StudioProperty(type=BOOLEAN) void setModal(boolean modal)
      Sets whether dialog should be modal
      Parameters:
      modal - modal
    • isModal

      boolean isModal()
      Returns:
      whether dialog should be modal
    • setStyleName

      @StudioProperty(name="stylename", type=CSS_CLASSNAME_LIST) void setStyleName(String styleName)
      Sets dialog style name.
      Parameters:
      styleName - style name
    • getStyleName

      @Nullable String getStyleName()
      Returns:
      dialog style name
    • setWidth

      @StudioProperty(type=SIZE) void setWidth(@Nullable String width)
      Sets dialog width.
      Parameters:
      width - width
    • getWidth

      float getWidth()
      Returns:
      dialog width
    • getWidthSizeUnit

      SizeUnit getWidthSizeUnit()
      Returns:
      dialog width size unit
    • setHeight

      @StudioProperty(type=SIZE) void setHeight(@Nullable String height)
      Sets dialog height.
      Parameters:
      height - height
    • getHeight

      float getHeight()
      Returns:
      dialog height
    • getHeightSizeUnit

      SizeUnit getHeightSizeUnit()
      Returns:
      dialog height size unit
    • setActionTarget

      @StudioProperty(name="onAction", type=COMPONENT_REF, options="io.jmix.ui.action.Action") void setActionTarget(@Nullable String actionId)
      Sets that dialog should be shown when action with id actionId is performed.
      Parameters:
      actionId - action id
    • getActionTarget

      @Nullable String getActionTarget()
      Returns:
      id of action that triggers dialog
    • setButtonTarget

      @StudioProperty(name="onButton", type=COMPONENT_REF, options="io.jmix.ui.component.Button") void setButtonTarget(@Nullable String buttonId)
      Sets that dialog should be shown when button with id actionId is clicked.
      Parameters:
      buttonId - button id
    • getButtonTarget

      @Nullable String getButtonTarget()
      Returns:
      id of button that triggers dialog
    • setCloseOnClickOutside

      @StudioProperty(type=BOOLEAN) void setCloseOnClickOutside(boolean closeOnClickOutside)
      Sets whether the dialog should be closed on click outside.
      Parameters:
      closeOnClickOutside - close on click outside
    • isCloseOnClickOutside

      boolean isCloseOnClickOutside()
      Returns:
      whether the dialog should be closed on click outside
    • setHtmlSanitizerEnabled

      @StudioProperty(type=BOOLEAN, defaultValue="true") void setHtmlSanitizerEnabled(boolean htmlSanitizerEnabled)
      Sets whether html sanitizer is enabled or not for dialog content.
      Parameters:
      htmlSanitizerEnabled - specifies whether html sanitizer is enabled
    • isHtmlSanitizerEnabled

      boolean isHtmlSanitizerEnabled()
      Returns:
      html sanitizer is enabled for dialog content
    • show

      void show()
      Shows dialog.