LuaPopupControl

This type represents the base for a popup. It is used to create custom windows that can be dragged and have children elements.

You can use this as a base type for any windows for your scripts, such as custom menus. If you wish to have a simple draggable, look at LuaWidgetControl instead.

circle-info

This is just a control type, to learn how to create custom controls, see LuaControlProto documentation.

__call

Constructor

Constructs the custom popup.

Arguments

Name

Type

Description

id

ControlID|string

ID.

proto

Prototype for this control

position

Custom offset

size

Custom size

Returns

Type

Description

LuaPopupControl

Custom popup instance.

Example


allowMove

Field

Type: bool

If set to true, allows the window to be dragged normally.


isActionPopup

Field

Type: bool

If set to true, will treat this as an action popup. Action popups are any popups that close if you click outside of them, such as the list on a combo box, or a color picker.


Open

Method

This makes the pop up appear once.

Arguments

None.

Returns

Nothing.

Example


Close

Method

This makes the pop up disappear forever.

circle-exclamation

Arguments

None.

Returns

Nothing.

Example

Last updated