Package com.storedobject.ui
Class ModuleMenu
java.lang.Object
com.vaadin.flow.component.Component
com.vaadin.flow.component.HtmlComponent
com.vaadin.flow.component.HtmlContainer
com.vaadin.flow.component.html.Div
- All Implemented Interfaces:
SingletonLogic,ViewSelected,ClickHandler,CloseableView,ExecutableView,ValueChangeHandler,com.vaadin.flow.component.AttachNotifier,com.vaadin.flow.component.ClickNotifier<com.vaadin.flow.component.html.Div>,com.vaadin.flow.component.ComponentEventListener<com.vaadin.flow.component.ClickEvent<? extends com.vaadin.flow.component.Component>>,com.vaadin.flow.component.DetachNotifier,com.vaadin.flow.component.HasComponents,com.vaadin.flow.component.HasElement,com.vaadin.flow.component.HasEnabled,com.vaadin.flow.component.HasOrderedComponents,com.vaadin.flow.component.HasSize,com.vaadin.flow.component.HasStyle,com.vaadin.flow.component.HasText,com.vaadin.flow.component.HasValue.ValueChangeListener,Serializable,Runnable,EventListener
- Direct Known Subclasses:
HomeModuleMenu
public class ModuleMenu
extends CardDashboard<ModuleLogic>
implements CloseableView, SingletonLogic, ViewSelected
An image-based menu to be created from the logic defined via an
ApplicationModule instance.- Author:
- Syam
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from interface com.storedobject.vaadin.ClickHandler
ClickHandler.ModifiedClickEvent<C extends com.vaadin.flow.component.Component>Nested classes/interfaces inherited from interface com.vaadin.flow.component.HasText
com.vaadin.flow.component.HasText.WhiteSpace -
Constructor Summary
ConstructorsConstructorDescriptionModuleMenu(Application application) Constructor.ModuleMenu(Application application, ApplicationModule module) Constructor.ModuleMenu(Application application, String moduleName) Constructor. -
Method Summary
Methods inherited from class com.storedobject.ui.CardDashboard
addCardSelectedListener, execute, getCaption, getCards, getGrid, getSelectedCard, getSelectedCards, getSelectionMode, getView, ignoreSelection, isIgnoreSelection, selectAllCards, setCaption, setSelectionModeMethods inherited from class com.storedobject.ui.ScrollingContent
getContent, getHeader, getMargin, setContent, setHeader, setHeaderHeight, setMarginMethods inherited from class com.vaadin.flow.component.HtmlComponent
getTitle, setTitleMethods inherited from class com.vaadin.flow.component.Component
addListener, findAncestor, fireEvent, from, get, getChildren, getElement, getEventBus, getId, getListeners, getLocale, getParent, getTranslation, getTranslation, getTranslation, getTranslation, getTranslation, getTranslation, getUI, hasListener, isAttached, isTemplateMapped, isVisible, onAttach, 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.storedobject.vaadin.ClickHandler
clicked, doubleClicked, onComponentEvent, rightClickedMethods inherited from interface com.vaadin.flow.component.ClickNotifier
addClickListener, addClickShortcut, addDoubleClickListener, addSingleClickListenerMethods inherited from interface com.vaadin.flow.component.DetachNotifier
addDetachListenerMethods inherited from interface com.storedobject.vaadin.ExecutableView
abort, clean, clearAlerts, close, createMenuItem, error, execute, getApplication, getMenuIconName, getMenuItem, getView, invoke, isCloseable, isFullScreen, isHomeView, log, log, message, returnedFrom, run, setClickable, speak, trackValueChange, tray, valueChanged, warningMethods inherited from interface com.vaadin.flow.component.HasComponents
add, add, add, addComponentAsFirst, addComponentAtIndex, remove, remove, removeAllMethods 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.HasOrderedComponents
getChildren, getComponentAt, getComponentCount, indexOf, replaceMethods 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.HasText
getText, getWhiteSpace, setText, setWhiteSpaceMethods inherited from interface com.storedobject.vaadin.ValueChangeHandler
valueChanged
-
Constructor Details
-
ModuleMenu
Constructor.Note: The caption of the currently running logic will be taken as the name of the application module.
- Parameters:
application- Application.
-
ModuleMenu
Constructor.- Parameters:
application- Application.moduleName- Name of the application module where the logic definitions are stored.
-
ModuleMenu
Constructor.- Parameters:
application- Application.module- Application module where the logic definitions are stored.
-
-
Method Details
-
viewSelected
public void viewSelected()- Specified by:
viewSelectedin interfaceViewSelected
-
clicked
public void clicked(com.vaadin.flow.component.Component c) Description copied from interface:ExecutableViewDefault implementation, does nothing.- Specified by:
clickedin interfaceClickHandler- Specified by:
clickedin interfaceExecutableView- Parameters:
c- Component
-
getSize
public int getSize()Get the size of the menu block in pixels to be shown on the screen.- Returns:
- Default is 250 if not defined in the
ApplicationModule.getSize().
-
getFontSize
Get the font-size of the menu title.- Returns:
- The CSS value representing the font-size. Default is "larger" if not defined in
the
ApplicationModule.getFontSize().
-