ProtectedconstructorOptionalisInternalConstructor: booleanProtected_The layout that holds the button elements.
Protected_The main UI layout.
Protected_The layout that holds the custom element.
Protected_Protected_Protected_The displayed icon.
Protected_Protected_The main UI layout.
Protected_The main message.
Protected_Label that displays the message.
Protected_The secondary message.
Protected_Label that displays the secondary message.
Protected_Protected_Type of the dialog box.
ReadonlyinitialThe initial title of the message box.
Callback executed when the user pressed button, or enter/escape are pressed.
Static ReadonlydefaultThe default window content padding to be used for modal windows.
Static ReadonlydefaultThe default window padding to be used for modal windows.
Static ReadonlykStatic ReadonlykStatic ReadonlykReturns the height of the content area of the window, in points. The content area represents the area of the window not including the title bar and the border.
Returns the height of the content area of the window, in pixels. The content area represents the area of the window not including the title bar and the border.
Returns the width of the content area of the window, in points. The content area represents the area of the window not including the title bar and the border.
Returns the width of the content area of the window, in pixels. The content area represents the area of the window not including the title bar and the border.
Sets the height of the window in points.
Sets the height of the window in pixels.
Check whether the window was destroyed.
Checks whether the window currently has keyboard focus.
Gets the key window which owns this window.
Returns the X position of the window in screen coordinates in points.
Specifies the local shortcut context. This context will be automatically disabled whenever the user switches focus from the context.
Gets the parent EditorWindow.
Gets the RenderWindow associated with this EditorWindow.
Specifies the global shortcut context. This context will be always enabled as long as the window is active.
Shows the remember my choice option to the user.
This feature is not compatible with custom elements that can be added to a message box using setCustomElement. If a custom element is set, it will be removed.
Determines the size of the keu window.
Sets the stylesheet for this window's UI surface.
Sets the stylesheet for this window's UI surface.
Returns the X position of the window in screen coordinates in points.
Sets the width of the window in points.
Sets the width of the window in pixels.
ProtectedautoAutomatically resizes the window for the current contents.
Shortcut triggered when Escape is pressed.
Centers the window within it's parent window.
Closes and destroys the window.
Shortcut triggered when enter is pressed.
Determines if the window is visible.
Triggered when one of the dialog box buttons was clicked.
Type of the button that was clicked.
Virtual
Called whenever the user or the program requested to close the window.
ProtectedonVirtual
Method to override to implement destruction of custom windows. Called by the engine before the window is destroyed.
ProtectedonVirtual
Method to override to implement custom behavior of a window, called by the engine once per frame.
ProtectedonVirtual
Method to override to implement custom behavior of a window, called by the engine once per frame,
once all the windows had their onEditorUpdate() method called.
Virtual
Method to override to implement initialization of custom windows. Called by the engine after window creation.
Virtual
Triggered whenever the window's screen dpi changes.
Virtual
Triggered whenever the window gains or loses focus.
True if focus was gained, false otherwise.
Virtual
Triggered whenever the window size changes.
New width of the window in pixels.
New height of the window in pixels.
Virtual
Adds a custom element to the message box.
The element to add to the message box.
OptionaloverflowScroll: boolean
If set, the element will be added to a scroll area if the height overflows The maximum height of the dialog box.
Defines the window maximum width and height in points.
Defines the window minimum width and height in points.
The minimum width of the window in points.
The minimum height of the window in points.
Moves the window on the desktop. Coordinates are in screen space using points.
Moves the window on the desktop. Coordinates are in screen space using pixels.
Resizes the window using a width and height in points.
Resizes the window using a width and height in pixels.
StaticconstructOpens a ModalWindow of the specified type.
The type of the ModalWindow to open.
OptionalmodalOptions: EnumValue<ModalWindowOption>OptionalparentWindow: KeyWindowBase | EditorWindowOptionalwindowOptions: anyProtected StaticconstructConstructs the Modal from script.
StaticmakeCreates a lambda functor that shows a message box when called. Depending on the user action the onConfirm or optionally, the onCancel
lambdas will be invoked.
Text to display in the title bar.
Message to display in the dialog box.
Secondary message to display in regular text.
Callback to trigger when the user clicks the 'Yes' button.
OptionalonCancel: () => void
Optional. Callback to trigger when the user clicks the 'No' button.
OptionalonShow: () => EnumValue<DialogBoxResultType, number>
Optional. Will be invoked when the message box is showned. If the value is set
and doesn't return null. The return value will be used to call either onConfirm or onCancel.
Optionalicon: Imagea lambda functor that shows a message box when called
This is a convenience API to be used to handle user-action on button presses or other UI elements. The use of this function is as in the following code example:
this.onDeleteButton.add(makeConfirmLambda("Item deletion",
"Do you really want to delete the item?",
"It will be lost forever.", () => this.deleteItem(value)));
StaticopenOpens a new message box with custom button labels.
A reference to the parent window that is opening this dialog box. If null will assume the active window.
Text to display in the title bar.
Message to display in the dialog box.
Secondary message to display in regular text.
An array of 1, 2 or 3 i18n strings.
OptionalonResult: (result: EnumValue<DialogBoxResultType>, messageBox: MessageBox) => void
Callback to trigger when the user clicks on a dialog box button.
Optionalicon: Image
Optional icon to display on the left side of the dialog.
OptionalrememberUserChoice: booleanInstance of the dialog box window.
Opens a new message box with predefined button labels.
A reference to the parent window that is opening this dialog box. If null will assume the active window.
Text to display in the title bar.
Message to display in the dialog box.
Secondary message to display in regular text.
Type of dialog box that determines what buttons to display.
OptionalonResult: (result: EnumValue<DialogBoxResultType>, messageBox: MessageBox) => void
Callback to trigger when the user clicks on a dialog box button.
Optionalicon: Image
Optional icon to display on the left side of the dialog.
OptionalrememberUserChoice: booleanInstance of the dialog box window.
StaticopenCreate a message box to confirm an action.
Text to display in the title bar.
Message to display in the dialog box.
Secondary message to display in regular text.
Callback to trigger when the user clicks the 'Yes' button.
OptionalonCancel: () => void
Optional. Callback to trigger when the user clicks the 'No' button.
OptionalonShow: () => EnumValue<DialogBoxResultType, number>
Optional. Will be invoked when the message box is showned. If the value is set
and doesn't return null. The return value will be used to call either onConfirm or onCancel.
Optionalicon: Imagea lambda functor that shows a message box when called
The MessageBox displays a message window containing a title, a message and a set of buttons. The class allows an easy and consistent way to query and inform the user. When the user click a button, an optional user callback is called and the window is closed.