public class Dialog extends Widget
Widget
and have some additional functionality. On show(Frame)
method it added to new
created DialogLayer
which forbid underlying layers to receive mouse click and keyboard events.Constructor and Description |
---|
Dialog()
Creates a dialog with default title text.
|
Dialog(float width,
float height)
Creates a dialog with default title text and specified position and size.
|
Dialog(java.lang.String title)
Creates a dialog with specified title text.
|
Dialog(java.lang.String title,
float width,
float height)
Creates a dialog with specified title text and specified position and size.
|
Dialog(java.lang.String title,
org.joml.Vector2f size)
Creates a dialog with specified title text and specified position and size.
|
Dialog(org.joml.Vector2f size)
Creates a dialog with default title text and specified position and size.
|
Modifier and Type | Method and Description |
---|---|
void |
close()
Used to close dialog.
|
void |
show(Frame frame)
Used to show title on specified frame.
|
addWidgetCloseEventListener, equals, getCloseButton, getCloseButtonBackgroundColor, getCloseButtonColor, getCloseIcon, getContainer, getMaximizeIcon, getMinimizeButton, getMinimizeIcon, getTitleBackgroundColor, getTitleContainer, getTitleHeight, getTitleTextState, getWidgetCloseEvents, hashCode, isCloseable, isDraggable, isMinimizable, isMinimized, isTitleEnabled, removeWidgetCloseEventListener, resize, setCloseable, setCloseButtonBackgroundColor, setCloseButtonColor, setCloseIcon, setContainer, setDraggable, setMaximizeIcon, setMinimizable, setMinimized, setMinimizeIcon, setSize, setSize, setTitleBackgroundColor, setTitleEnabled, setTitleHeight, toString
add, addAll, clearChilds, containerIterator, contains, containsAll, count, forEach, getAbsolutePosition, getBackgroundColor, getBorder, getChilds, getCornerRadius, getFocusedStrokeColor, getIntersector, getListenerMap, getMetadata, getParent, getPosition, getSize, getTooltip, intersects, isEmpty, isEnabled, isFocused, isHovered, isPressed, isVisible, parallelStream, remove, removeAll, removeIf, setBackgroundColor, setBackgroundColor, setBorder, setCornerRadius, setEnabled, setFocused, setFocusedStrokeColor, setFocusedStrokeColor, setHovered, setIntersector, setListenerMap, setParent, setPosition, setPosition, setPressed, setTooltip, setVisible, stream
public Dialog()
public Dialog(float width, float height)
width
- width of component.height
- height of component.public Dialog(org.joml.Vector2f size)
size
- size of component.public Dialog(java.lang.String title)
title
- dialog text.public Dialog(java.lang.String title, float width, float height)
title
- dialog text.width
- width of component.height
- height of component.public Dialog(java.lang.String title, org.joml.Vector2f size)
title
- widget text.size
- size of component.public void show(Frame frame)
frame
- frame to show dialog.public void close()