Class JmixMenuBar
java.lang.Object
com.vaadin.flow.component.Component
com.vaadin.flow.component.menubar.MenuBar
io.jmix.flowui.kit.component.menubar.JmixMenuBar
- All Implemented Interfaces:
com.vaadin.flow.component.AttachNotifier,com.vaadin.flow.component.BlurNotifier<JmixMenuBar>,com.vaadin.flow.component.contextmenu.HasMenuItems,com.vaadin.flow.component.DetachNotifier,com.vaadin.flow.component.Focusable<JmixMenuBar>,com.vaadin.flow.component.FocusNotifier<JmixMenuBar>,com.vaadin.flow.component.HasElement,com.vaadin.flow.component.HasEnabled,com.vaadin.flow.component.HasSize,com.vaadin.flow.component.HasStyle,com.vaadin.flow.component.HasTheme,com.vaadin.flow.component.shared.HasOverlayClassName,com.vaadin.flow.component.shared.HasThemeVariant<com.vaadin.flow.component.menubar.MenuBarVariant>,com.vaadin.flow.component.shared.HasTooltip,HasMenuItemsEnhanced,Serializable
public class JmixMenuBar
extends com.vaadin.flow.component.menubar.MenuBar
implements HasMenuItemsEnhanced, com.vaadin.flow.component.Focusable<JmixMenuBar>, com.vaadin.flow.component.shared.HasTooltip
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class com.vaadin.flow.component.menubar.MenuBar
com.vaadin.flow.component.menubar.MenuBar.MenuBarI18nNested classes/interfaces inherited from interface com.vaadin.flow.component.BlurNotifier
com.vaadin.flow.component.BlurNotifier.BlurEvent<C extends com.vaadin.flow.component.Component>Nested classes/interfaces inherited from interface com.vaadin.flow.component.FocusNotifier
com.vaadin.flow.component.FocusNotifier.FocusEvent<C extends com.vaadin.flow.component.Component> -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected com.vaadin.flow.component.contextmenu.MenuItemsArrayGenerator<com.vaadin.flow.component.contextmenu.MenuItem>protected JmixMenuManager<com.vaadin.flow.component.menubar.MenuBar,com.vaadin.flow.component.contextmenu.MenuItem, com.vaadin.flow.component.contextmenu.SubMenu> protected boolean -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionaddItem(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.protected voidattachListener(com.vaadin.flow.component.AttachEvent attachEvent) Stream<com.vaadin.flow.component.Component>List<com.vaadin.flow.component.contextmenu.MenuItem>getItems()protected voidprotected voidinitConnector(String appId) voidremove(com.vaadin.flow.component.contextmenu.MenuItem... items) voidprotected voidprotected voidrunBeforeClientResponse(com.vaadin.flow.function.SerializableConsumer<com.vaadin.flow.component.UI> command) protected voidMethods inherited from class com.vaadin.flow.component.menubar.MenuBar
addItem, addItem, addItem, addItem, close, getI18n, isOpenOnHover, isReverseCollapseOrder, isTabNavigation, onAttach, setI18n, setOpenOnHover, setReverseCollapseOrder, setTabNavigation, setTooltipTextMethods inherited from class com.vaadin.flow.component.Component
addListener, findAncestor, fireEvent, from, get, getElement, getEventBus, getId, getListeners, getLocale, getParent, getTranslation, getTranslation, getTranslation, getTranslation, getTranslation, getTranslation, getUI, hasListener, isAttached, isTemplateMapped, isVisible, onDetach, onEnabledStateChanged, removeFromParent, scrollIntoView, scrollIntoView, set, setElement, setId, setVisibleMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.vaadin.flow.component.AttachNotifier
addAttachListenerMethods inherited from interface com.vaadin.flow.component.BlurNotifier
addBlurListenerMethods inherited from interface com.vaadin.flow.component.DetachNotifier
addDetachListenerMethods inherited from interface com.vaadin.flow.component.Focusable
addFocusShortcut, blur, focus, getTabIndex, setTabIndexMethods inherited from interface com.vaadin.flow.component.FocusNotifier
addFocusListenerMethods inherited from interface com.vaadin.flow.component.HasElement
getElementMethods inherited from interface com.vaadin.flow.component.HasEnabled
isEnabled, setEnabledMethods inherited from interface com.vaadin.flow.component.shared.HasOverlayClassName
getOverlayClassName, setOverlayClassNameMethods inherited from interface com.vaadin.flow.component.HasSize
getHeight, getHeightUnit, getMaxHeight, getMaxWidth, getMinHeight, getMinWidth, getWidth, getWidthUnit, setHeight, setHeight, setHeightFull, setMaxHeight, setMaxHeight, setMaxWidth, setMaxWidth, setMinHeight, setMinHeight, setMinWidth, setMinWidth, setSizeFull, setSizeUndefined, setWidth, setWidth, setWidthFullMethods inherited from interface com.vaadin.flow.component.HasStyle
addClassName, addClassNames, getClassName, getClassNames, getStyle, hasClassName, removeClassName, removeClassNames, setClassName, setClassNameMethods inherited from interface com.vaadin.flow.component.HasTheme
addThemeName, addThemeNames, getThemeName, getThemeNames, hasThemeName, removeThemeName, removeThemeNames, setThemeName, setThemeNameMethods inherited from interface com.vaadin.flow.component.shared.HasThemeVariant
addThemeVariants, removeThemeVariantsMethods inherited from interface com.vaadin.flow.component.shared.HasTooltip
getTooltip, setTooltipText
-
Field Details
-
updateScheduled
protected boolean updateScheduled
-
Constructor Details
-
JmixMenuBar
public JmixMenuBar()
-
-
Method Details
-
initComponent
protected void initComponent() -
addItem
Description copied from interface:HasMenuItemsEnhancedAdds a new item component with the given text content to the context menu overlay.- Specified by:
addItemin interfaceHasMenuItemsEnhanced- Overrides:
addItemin classcom.vaadin.flow.component.menubar.MenuBar- Parameters:
text- the text content for the new item- Returns:
- the added
JmixMenuItemcomponent
-
addItem
Description copied from interface:HasMenuItemsEnhancedAdds a new item component with the given component to the context menu overlay.- Specified by:
addItemin interfaceHasMenuItemsEnhanced- Overrides:
addItemin classcom.vaadin.flow.component.menubar.MenuBar- Parameters:
component- the component inside the new item- Returns:
- the added
JmixMenuItemcomponent
-
addItem
public JmixMenuItem addItem(String text, com.vaadin.flow.component.ComponentEventListener<com.vaadin.flow.component.ClickEvent<com.vaadin.flow.component.contextmenu.MenuItem>> clickListener) Description copied from interface:HasMenuItemsEnhancedAdds a new item component with the given text content and click listener to the context menu overlay.- Specified by:
addItemin interfacecom.vaadin.flow.component.contextmenu.HasMenuItems- Specified by:
addItemin interfaceHasMenuItemsEnhanced- Overrides:
addItemin classcom.vaadin.flow.component.menubar.MenuBar- Parameters:
text- the text content for the new itemclickListener- the handler for clicking the new item, can benullto not add listener- Returns:
- the added
JmixMenuItemcomponent
-
addItem
public 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) Description copied from interface:HasMenuItemsEnhancedAdds a new item component with the given component and click listener to the context menu overlay.- Specified by:
addItemin interfacecom.vaadin.flow.component.contextmenu.HasMenuItems- Specified by:
addItemin interfaceHasMenuItemsEnhanced- Overrides:
addItemin classcom.vaadin.flow.component.menubar.MenuBar- Parameters:
component- the component inside the new itemclickListener- the handler for clicking the new item, can benullto not add listener- Returns:
- the added
JmixMenuItemcomponent
-
addItemAtIndex
Description copied from interface:HasMenuItemsEnhancedAdds a new item component with the given text content at the given position to the context menu overlay.- Specified by:
addItemAtIndexin interfaceHasMenuItemsEnhanced- Parameters:
index- item positiontext- the text content for the new item- Returns:
- the added
JmixMenuItemcomponent
-
addItemAtIndex
Description copied from interface:HasMenuItemsEnhancedAdds a new item component with the given component at the given position to the context menu overlay.- Specified by:
addItemAtIndexin interfaceHasMenuItemsEnhanced- Parameters:
index- item positioncomponent- the component inside the new item- Returns:
- the added
JmixMenuItemcomponent
-
addItemAtIndex
public JmixMenuItem addItemAtIndex(int index, String text, com.vaadin.flow.component.ComponentEventListener<com.vaadin.flow.component.ClickEvent<com.vaadin.flow.component.contextmenu.MenuItem>> clickListener) Description copied from interface:HasMenuItemsEnhancedAdds a new item component with the given text content and click listener at the given position to the context menu overlay.- Specified by:
addItemAtIndexin interfaceHasMenuItemsEnhanced- Parameters:
index- item positiontext- the text content for the new itemclickListener- the handler for clicking the new item, can benullto not add listener- Returns:
- the added
JmixMenuItemcomponent
-
addItemAtIndex
public 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) Description copied from interface:HasMenuItemsEnhancedAdds a new item component with the given component and click listener at the given position to the context menu overlay.- Specified by:
addItemAtIndexin interfaceHasMenuItemsEnhanced- Parameters:
index- item positioncomponent- the component inside the new itemclickListener- the handler for clicking the new item, can benullto not add listener- Returns:
- the added
JmixMenuItemcomponent
-
getItems
- Overrides:
getItemsin classcom.vaadin.flow.component.menubar.MenuBar
-
removeAll
public void removeAll()- Overrides:
removeAllin classcom.vaadin.flow.component.menubar.MenuBar
-
getChildren
- Overrides:
getChildrenin classcom.vaadin.flow.component.menubar.MenuBar
-
resetContent
protected void resetContent() -
updateButtons
protected void updateButtons() -
attachListener
protected void attachListener(com.vaadin.flow.component.AttachEvent attachEvent) -
initConnector
-
runBeforeClientResponse
protected void runBeforeClientResponse(com.vaadin.flow.function.SerializableConsumer<com.vaadin.flow.component.UI> command)
-