Package io.jmix.flowui.screen
Class DialogWindow<S extends Screen<?>>
java.lang.Object
io.jmix.flowui.screen.DialogWindow<S>
- All Implemented Interfaces:
com.vaadin.flow.component.HasElement,com.vaadin.flow.component.HasSize,com.vaadin.flow.component.HasTheme,Serializable,org.springframework.beans.factory.Aware,org.springframework.beans.factory.InitializingBean,org.springframework.context.ApplicationContextAware
public class DialogWindow<S extends Screen<?>>
extends Object
implements com.vaadin.flow.component.HasSize, com.vaadin.flow.component.HasTheme, org.springframework.context.ApplicationContextAware, org.springframework.beans.factory.InitializingBean
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classDialogWindow.AfterCloseEvent<S extends Screen<?>>static classDialogWindow.AfterOpenEvent<S extends Screen<?>> -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncom.vaadin.flow.shared.RegistrationaddAfterCloseListener(Consumer<DialogWindow.AfterCloseEvent<S>> listener) com.vaadin.flow.shared.RegistrationaddAfterOpenListener(Consumer<DialogWindow.AfterOpenEvent<S>> listener) voidaddThemeName(String themeName) voidaddThemeNames(String... themeNames) voidprotected voidapplyDialogModeSettings(S screen) voidclose()voidclose(boolean force) protected voidprotected com.vaadin.flow.component.dialog.Dialogprotected com.vaadin.flow.component.orderedlayout.VerticalLayoutprotected com.vaadin.flow.component.html.HeadercreateHeader(String screenTitle) protected com.vaadin.flow.component.button.Buttonprotected com.vaadin.flow.component.ComponentcreateScreenWrapper(S screen) protected voidfireScreenAfterShowEvent(Screen screen) protected voidfireScreenBeforeShowEvent(Screen screen) com.vaadin.flow.dom.Elementprotected EventHubOptional<com.vaadin.flow.component.Unit>com.vaadin.flow.dom.ThemeListgetWidth()Optional<com.vaadin.flow.component.Unit>protected booleanhasSubscriptions(Class<?> eventClass) booleanhasThemeName(String themeName) protected voidinitDialog(com.vaadin.flow.component.dialog.Dialog dialog) protected voidinitScreen(S screen) booleanbooleanbooleanbooleanisModal()booleanprotected Messagesmessages()protected voidonCloseButtonClicked(com.vaadin.flow.component.ClickEvent<com.vaadin.flow.component.button.Button> event) protected voidonDialogCloseAction(com.vaadin.flow.component.dialog.Dialog.DialogCloseActionEvent event) protected voidonDialogOpenedChanged(com.vaadin.flow.component.dialog.GeneratedVaadinDialog.OpenedChangeEvent<com.vaadin.flow.component.dialog.Dialog> openedChangeEvent) protected voidonScreenAfterClosed(Screen.AfterCloseEvent closeEvent) voidopen()protected <E> voidbooleanremoveThemeName(String themeName) voidremoveThemeNames(String... themeNames) voidsetApplicationContext(org.springframework.context.ApplicationContext applicationContext) voidsetCloseOnEsc(boolean closeOnEsc) voidsetCloseOnOutsideClick(boolean closeOnOutsideClick) voidsetDraggable(boolean draggable) voidsetHeight(float height, com.vaadin.flow.component.Unit unit) voidvoidvoidsetMaxHeight(float maxHeight, com.vaadin.flow.component.Unit unit) voidsetMaxHeight(String maxHeight) voidsetMaxWidth(float maxWidth, com.vaadin.flow.component.Unit unit) voidsetMaxWidth(String maxWidth) voidsetMinHeight(float minHeight, com.vaadin.flow.component.Unit unit) voidsetMinHeight(String minHeight) voidsetMinWidth(float minWidth, com.vaadin.flow.component.Unit unit) voidsetMinWidth(String minWidth) voidsetModal(boolean modal) voidsetResizable(boolean resizable) voidvoidvoidsetThemeName(String themeName) voidsetThemeName(String themeName, boolean set) protected voidsetValueIfPresent(String value, Consumer<String> setter) voidsetWidth(float width, com.vaadin.flow.component.Unit unit) voidvoidprotected UiComponents
-
Field Details
-
BASE_STYLE_NAME
- See Also:
-
dialog
protected com.vaadin.flow.component.dialog.Dialog dialog -
screen
-
applicationContext
protected org.springframework.context.ApplicationContext applicationContext
-
-
Constructor Details
-
DialogWindow
-
-
Method Details
-
setApplicationContext
public void setApplicationContext(org.springframework.context.ApplicationContext applicationContext) throws org.springframework.beans.BeansException - Specified by:
setApplicationContextin interfaceorg.springframework.context.ApplicationContextAware- Throws:
org.springframework.beans.BeansException
-
afterPropertiesSet
public void afterPropertiesSet()- Specified by:
afterPropertiesSetin interfaceorg.springframework.beans.factory.InitializingBean
-
initScreen
-
createDialog
protected com.vaadin.flow.component.dialog.Dialog createDialog() -
initDialog
protected void initDialog(com.vaadin.flow.component.dialog.Dialog dialog) -
applyDialogModeSettings
-
setValueIfPresent
-
createHeader
-
createHeaderCloseButton
protected com.vaadin.flow.component.button.Button createHeaderCloseButton() -
onCloseButtonClicked
protected void onCloseButtonClicked(com.vaadin.flow.component.ClickEvent<com.vaadin.flow.component.button.Button> event) -
createScreenWrapper
-
createDialogOverlay
protected com.vaadin.flow.component.orderedlayout.VerticalLayout createDialogOverlay() -
getEventHub
-
publish
-
hasSubscriptions
-
getScreen
-
open
public void open() -
close
public void close() -
close
public void close(boolean force) -
closeInternal
protected void closeInternal() -
onDialogOpenedChanged
protected void onDialogOpenedChanged(com.vaadin.flow.component.dialog.GeneratedVaadinDialog.OpenedChangeEvent<com.vaadin.flow.component.dialog.Dialog> openedChangeEvent) -
onScreenAfterClosed
-
fireScreenBeforeShowEvent
-
fireScreenAfterShowEvent
-
onDialogCloseAction
protected void onDialogCloseAction(com.vaadin.flow.component.dialog.Dialog.DialogCloseActionEvent event) -
addAfterOpenListener
public com.vaadin.flow.shared.Registration addAfterOpenListener(Consumer<DialogWindow.AfterOpenEvent<S>> listener) -
addAfterCloseListener
public com.vaadin.flow.shared.Registration addAfterCloseListener(Consumer<DialogWindow.AfterCloseEvent<S>> listener) -
getElement
public com.vaadin.flow.dom.Element getElement()- Specified by:
getElementin interfacecom.vaadin.flow.component.HasElement
-
isCloseOnEsc
public boolean isCloseOnEsc() -
setCloseOnEsc
public void setCloseOnEsc(boolean closeOnEsc) -
isCloseOnOutsideClick
public boolean isCloseOnOutsideClick() -
setCloseOnOutsideClick
public void setCloseOnOutsideClick(boolean closeOnOutsideClick) -
isModal
public boolean isModal() -
setModal
public void setModal(boolean modal) -
isDraggable
public boolean isDraggable() -
setDraggable
public void setDraggable(boolean draggable) -
isResizable
public boolean isResizable() -
setResizable
public void setResizable(boolean resizable) -
setWidth
- Specified by:
setWidthin interfacecom.vaadin.flow.component.HasSize
-
setWidth
public void setWidth(float width, com.vaadin.flow.component.Unit unit) - Specified by:
setWidthin interfacecom.vaadin.flow.component.HasSize
-
setMinWidth
- Specified by:
setMinWidthin interfacecom.vaadin.flow.component.HasSize
-
setMinWidth
public void setMinWidth(float minWidth, com.vaadin.flow.component.Unit unit) - Specified by:
setMinWidthin interfacecom.vaadin.flow.component.HasSize
-
setMaxWidth
- Specified by:
setMaxWidthin interfacecom.vaadin.flow.component.HasSize
-
setMaxWidth
public void setMaxWidth(float maxWidth, com.vaadin.flow.component.Unit unit) - Specified by:
setMaxWidthin interfacecom.vaadin.flow.component.HasSize
-
getWidth
- Specified by:
getWidthin interfacecom.vaadin.flow.component.HasSize
-
getMinWidth
- Specified by:
getMinWidthin interfacecom.vaadin.flow.component.HasSize
-
getMaxWidth
- Specified by:
getMaxWidthin interfacecom.vaadin.flow.component.HasSize
-
getWidthUnit
- Specified by:
getWidthUnitin interfacecom.vaadin.flow.component.HasSize
-
setHeight
- Specified by:
setHeightin interfacecom.vaadin.flow.component.HasSize
-
setHeight
public void setHeight(float height, com.vaadin.flow.component.Unit unit) - Specified by:
setHeightin interfacecom.vaadin.flow.component.HasSize
-
setMinHeight
- Specified by:
setMinHeightin interfacecom.vaadin.flow.component.HasSize
-
setMinHeight
public void setMinHeight(float minHeight, com.vaadin.flow.component.Unit unit) - Specified by:
setMinHeightin interfacecom.vaadin.flow.component.HasSize
-
setMaxHeight
- Specified by:
setMaxHeightin interfacecom.vaadin.flow.component.HasSize
-
setMaxHeight
public void setMaxHeight(float maxHeight, com.vaadin.flow.component.Unit unit) - Specified by:
setMaxHeightin interfacecom.vaadin.flow.component.HasSize
-
getHeight
- Specified by:
getHeightin interfacecom.vaadin.flow.component.HasSize
-
getMinHeight
- Specified by:
getMinHeightin interfacecom.vaadin.flow.component.HasSize
-
getMaxHeight
- Specified by:
getMaxHeightin interfacecom.vaadin.flow.component.HasSize
-
getHeightUnit
- Specified by:
getHeightUnitin interfacecom.vaadin.flow.component.HasSize
-
setSizeFull
public void setSizeFull()- Specified by:
setSizeFullin interfacecom.vaadin.flow.component.HasSize
-
setWidthFull
public void setWidthFull()- Specified by:
setWidthFullin interfacecom.vaadin.flow.component.HasSize
-
setHeightFull
public void setHeightFull()- Specified by:
setHeightFullin interfacecom.vaadin.flow.component.HasSize
-
setSizeUndefined
public void setSizeUndefined()- Specified by:
setSizeUndefinedin interfacecom.vaadin.flow.component.HasSize
-
addThemeName
- Specified by:
addThemeNamein interfacecom.vaadin.flow.component.HasTheme
-
removeThemeName
- Specified by:
removeThemeNamein interfacecom.vaadin.flow.component.HasTheme
-
setThemeName
- Specified by:
setThemeNamein interfacecom.vaadin.flow.component.HasTheme
-
getThemeName
- Specified by:
getThemeNamein interfacecom.vaadin.flow.component.HasTheme
-
getThemeNames
public com.vaadin.flow.dom.ThemeList getThemeNames()- Specified by:
getThemeNamesin interfacecom.vaadin.flow.component.HasTheme
-
setThemeName
- Specified by:
setThemeNamein interfacecom.vaadin.flow.component.HasTheme
-
hasThemeName
- Specified by:
hasThemeNamein interfacecom.vaadin.flow.component.HasTheme
-
addThemeNames
- Specified by:
addThemeNamesin interfacecom.vaadin.flow.component.HasTheme
-
removeThemeNames
- Specified by:
removeThemeNamesin interfacecom.vaadin.flow.component.HasTheme
-
messages
-
uiComponents
-