Interface HasMenuItemsEnhanced

All Superinterfaces:
Serializable
All Known Implementing Classes:
JmixMenuBar, JmixMenuBarSubMenu, JmixSubMenu

public interface HasMenuItemsEnhanced extends Serializable
Interface defining methods for components that can have JmixMenuItems inside them.
  • Method Summary

    Modifier and Type
    Method
    Description
    addItem(com.vaadin.flow.component.Component component)
    Adds a new item component with the given component to the context menu overlay.
    addItem(com.vaadin.flow.component.Component component, com.vaadin.flow.component.ComponentEventListener<com.vaadin.flow.component.ClickEvent<com.vaadin.flow.component.contextmenu.MenuItem>> clickListener)
    Adds a new item component with the given component and click listener to the context menu overlay.
    Adds a new item component with the given text content to the context menu overlay.
    addItem(String text, com.vaadin.flow.component.ComponentEventListener<com.vaadin.flow.component.ClickEvent<com.vaadin.flow.component.contextmenu.MenuItem>> clickListener)
    Adds a new item component with the given text content and click listener to the context menu overlay.
    addItemAtIndex(int index, com.vaadin.flow.component.Component component)
    Adds a new item component with the given component at the given position to the context menu overlay.
    addItemAtIndex(int index, com.vaadin.flow.component.Component component, com.vaadin.flow.component.ComponentEventListener<com.vaadin.flow.component.ClickEvent<com.vaadin.flow.component.contextmenu.MenuItem>> clickListener)
    Adds a new item component with the given component and click listener at the given position to the context menu overlay.
    addItemAtIndex(int index, String text)
    Adds a new item component with the given text content at the given position to the context menu overlay.
    addItemAtIndex(int index, String text, com.vaadin.flow.component.ComponentEventListener<com.vaadin.flow.component.ClickEvent<com.vaadin.flow.component.contextmenu.MenuItem>> clickListener)
    Adds a new item component with the given text content and click listener at the given position to the context menu overlay.
  • Method Details

    • addItem

      JmixMenuItem addItem(String text)
      Adds a new item component with the given text content to the context menu overlay.
      Parameters:
      text - the text content for the new item
      Returns:
      the added JmixMenuItem component
    • addItem

      JmixMenuItem addItem(com.vaadin.flow.component.Component component)
      Adds a new item component with the given component to the context menu overlay.
      Parameters:
      component - the component inside the new item
      Returns:
      the added JmixMenuItem component
    • addItem

      JmixMenuItem addItem(String text, com.vaadin.flow.component.ComponentEventListener<com.vaadin.flow.component.ClickEvent<com.vaadin.flow.component.contextmenu.MenuItem>> clickListener)
      Adds a new item component with the given text content and click listener to the context menu overlay.
      Parameters:
      text - the text content for the new item
      clickListener - the handler for clicking the new item, can be null to not add listener
      Returns:
      the added JmixMenuItem component
    • addItem

      JmixMenuItem addItem(com.vaadin.flow.component.Component component, com.vaadin.flow.component.ComponentEventListener<com.vaadin.flow.component.ClickEvent<com.vaadin.flow.component.contextmenu.MenuItem>> clickListener)
      Adds a new item component with the given component and click listener to the context menu overlay.
      Parameters:
      component - the component inside the new item
      clickListener - the handler for clicking the new item, can be null to not add listener
      Returns:
      the added JmixMenuItem component
    • addItemAtIndex

      JmixMenuItem addItemAtIndex(int index, String text)
      Adds a new item component with the given text content at the given position to the context menu overlay.
      Parameters:
      index - item position
      text - the text content for the new item
      Returns:
      the added JmixMenuItem component
    • addItemAtIndex

      JmixMenuItem addItemAtIndex(int index, com.vaadin.flow.component.Component component)
      Adds a new item component with the given component at the given position to the context menu overlay.
      Parameters:
      index - item position
      component - the component inside the new item
      Returns:
      the added JmixMenuItem component
    • addItemAtIndex

      JmixMenuItem addItemAtIndex(int index, String text, com.vaadin.flow.component.ComponentEventListener<com.vaadin.flow.component.ClickEvent<com.vaadin.flow.component.contextmenu.MenuItem>> clickListener)
      Adds a new item component with the given text content and click listener at the given position to the context menu overlay.
      Parameters:
      index - item position
      text - the text content for the new item
      clickListener - the handler for clicking the new item, can be null to not add listener
      Returns:
      the added JmixMenuItem component
    • addItemAtIndex

      JmixMenuItem addItemAtIndex(int index, com.vaadin.flow.component.Component component, com.vaadin.flow.component.ComponentEventListener<com.vaadin.flow.component.ClickEvent<com.vaadin.flow.component.contextmenu.MenuItem>> clickListener)
      Adds a new item component with the given component and click listener at the given position to the context menu overlay.
      Parameters:
      index - item position
      component - the component inside the new item
      clickListener - the handler for clicking the new item, can be null to not add listener
      Returns:
      the added JmixMenuItem component