Package io.jmix.ui.component.impl
Class AbstractActionsHolderComponent<T extends com.vaadin.ui.AbstractComponent & com.vaadin.event.Action.ShortcutNotifier>
java.lang.Object
io.jmix.ui.component.impl.AbstractComponent<T>
io.jmix.ui.component.impl.AbstractActionsHolderComponent<T>
- All Implemented Interfaces:
ActionsHolder,AttachNotifier,Component,Component.BelongToFrame,Component.HasCaption,Component.HasDescription,Component.HasIcon,Component.HasXmlDescriptor,Component.Wrapper,HasContextHelp,HasDebugId,HasHtmlCaption,HasHtmlDescription,HasHtmlSanitizer,HasSubParts,SecuredActionsHolder
- Direct Known Subclasses:
AbstractTable
public abstract class AbstractActionsHolderComponent<T extends com.vaadin.ui.AbstractComponent & com.vaadin.event.Action.ShortcutNotifier>
extends AbstractComponent<T>
implements SecuredActionsHolder
Base class for action holders with shortcuts support
-
Nested Class Summary
Nested classes/interfaces inherited from interface io.jmix.ui.component.Component
Component.Alignment, Component.BelongToFrame, Component.Disposable, Component.Editable, Component.Focusable, Component.HasCaption, Component.HasDescription, Component.HasIcon, Component.HasXmlDescriptor, Component.WrapperNested classes/interfaces inherited from interface io.jmix.ui.component.HasContextHelp
HasContextHelp.ContextHelpIconClickEvent -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected Map<Action,JmixButton> protected Consumer<PropertyChangeEvent>protected ActionsPermissionsprotected com.vaadin.ui.VerticalLayoutprotected ShortcutsDelegate<com.vaadin.event.ShortcutListener>protected booleanFields inherited from class io.jmix.ui.component.impl.AbstractComponent
alignment, applicationContext, component, contextHelpIconClickHandler, contextHelpIconClickListener, descriptionAsHtml, element, frame, htmlSanitizerEnabled, icon, ICON_STYLE, id, parentFields inherited from interface io.jmix.ui.component.Component
AUTO_SIZE, AUTO_SIZE_PX, FULL_SIZE -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidvoidAdd an action to the componentvoidAdd an action to the component with index.protected voidattachAction(Action action) protected voidprotected abstract JmixButtonprotected com.vaadin.ui.VerticalLayoutprotected ShortcutsDelegate<com.vaadin.event.ShortcutListener>protected voidinitContextMenuButton(JmixButton contextMenuButton, Action action) protected voidinitContextMenuPopup(com.vaadin.ui.VerticalLayout contextMenuPopup) voidremoveAction(Action action) Remove the action from the componentvoidremoveAction(String id) Remove the action by its ID.voidRemove all actions from the componentprotected voidsetContextMenuButtonAction(JmixButton button, Action action) protected voidsetContextMenuButtonCaption(JmixButton button, String caption, KeyCombination shortcutCombination) protected voidsetContextMenuButtonIcon(JmixButton button, String icon) voidsetThemeConstantsManager(ThemeConstantsManager themeConstantsManager) Methods inherited from class io.jmix.ui.component.impl.AbstractComponent
addAttachListener, addDetachListener, addStyleName, assignDebugId, attached, detached, getAlignment, getCaption, getComponent, getComposition, getContextHelpIconClickHandler, getContextHelpText, getDebugId, getDescription, getEventHub, getFrame, getHeight, getHeightSizeUnit, getHtmlSanitizer, getIcon, getIconName, getIconResource, getId, getParent, getStyleName, getUiComponentProperties, getUiProperties, getWidth, getWidthSizeUnit, getXmlDescriptor, hasSubscriptions, hasValidationError, isAttached, isCaptionAsHtml, isContextHelpTextHtmlEnabled, isDescriptionAsHtml, isEnabled, isEnabledRecursive, isHtmlSanitizerEnabled, isResponsive, isVisible, isVisibleRecursive, onContextHelpIconClick, publish, removeStyleName, sanitize, setAlignment, setApplicationContext, setCaption, setCaptionAsHtml, setContextHelpIconClickHandler, setContextHelpText, setContextHelpTextHtmlEnabled, setDebugId, setDescription, setDescriptionAsHtml, setEnabled, setFrame, setHeight, setHtmlSanitizerEnabled, setIcon, setIconFromSet, setId, setParent, setResponsive, setStyleName, setValidationError, setVisible, setWidth, setXmlDescriptor, unsubscribe, unwrap, unwrapComposition, unwrapCompositionOrNull, unwrapOrNull, withUnwrapped, withUnwrappedCompositionMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface io.jmix.ui.component.ActionsHolder
getActionNN, getSubPartMethods inherited from interface io.jmix.ui.component.Component
addStyleName, getAlignment, getHeight, getHeightSizeUnit, getId, getParent, getStyleName, getWidth, getWidthSizeUnit, isEnabled, isEnabledRecursive, isResponsive, isVisible, isVisibleRecursive, removeStyleName, setAlignment, setEnabled, setHeight, setHeightAuto, setHeightFull, setId, setParent, setResponsive, setSizeAuto, setSizeFull, setStyleName, setVisible, setWidth, setWidthAuto, setWidthFull, unwrap, unwrapComposition, unwrapCompositionOrNull, unwrapOrNull, withUnwrapped, withUnwrappedComposition
-
Field Details
-
actionList
-
actionButtons
-
contextMenuPopup
protected com.vaadin.ui.VerticalLayout contextMenuPopup -
shortcutsDelegate
-
actionsPermissions
-
showIconsForPopupMenuActions
protected boolean showIconsForPopupMenuActions -
actionPropertyChangeListener
-
-
Constructor Details
-
AbstractActionsHolderComponent
protected AbstractActionsHolderComponent()
-
-
Method Details
-
createContextMenuPopup
protected com.vaadin.ui.VerticalLayout createContextMenuPopup() -
initContextMenuPopup
protected void initContextMenuPopup(com.vaadin.ui.VerticalLayout contextMenuPopup) -
createShortcutsDelegate
-
actionPropertyChanged
-
setContextMenuButtonCaption
protected void setContextMenuButtonCaption(JmixButton button, @Nullable String caption, @Nullable KeyCombination shortcutCombination) -
setContextMenuButtonIcon
-
setContextMenuButtonAction
-
beforeContextMenuButtonHandlerPerformed
protected void beforeContextMenuButtonHandlerPerformed() -
setThemeConstantsManager
-
addAction
Description copied from interface:ActionsHolderAdd an action to the component- Specified by:
addActionin interfaceActionsHolder
-
addAction
Description copied from interface:ActionsHolderAdd an action to the component with index.- Specified by:
addActionin interfaceActionsHolder
-
initContextMenuButton
-
attachAction
-
createContextMenuButton
-
removeAction
Description copied from interface:ActionsHolderRemove the action from the component- Specified by:
removeActionin interfaceActionsHolder
-
removeAction
Description copied from interface:ActionsHolderRemove the action by its ID. If there is no action with that ID, nothing happens.- Specified by:
removeActionin interfaceActionsHolder
-
removeAllActions
public void removeAllActions()Description copied from interface:ActionsHolderRemove all actions from the component- Specified by:
removeAllActionsin interfaceActionsHolder
-
getActions
- Specified by:
getActionsin interfaceActionsHolder- Returns:
- unmodifiable collection of actions
-
getAction
- Specified by:
getActionin interfaceActionsHolder- Returns:
- an action by its ID, or null if not found
-
getActionsPermissions
- Specified by:
getActionsPermissionsin interfaceSecuredActionsHolder- Returns:
- permissions container
-