Skip to content

Class: MockCUIListBoxItemMsgChain

Mock UI list box message chain.

Extends

Implements

  • CUIListBoxItemMsgChain

Accessors

__name

Get Signature

ts
get __name(): string;
Returns

string

Implementation of

ts
CUIListBoxItemMsgChain.__name

Inherited from

MockCUIListBoxItem.__name


__name

Get Signature

ts
get static __name(): string;
Returns

string

Inherited from

MockCUIListBoxItem.__name

Constructors

Constructor

ts
new MockCUIListBoxItemMsgChain(): MockCUIListBoxItemMsgChain;

Returns

MockCUIListBoxItemMsgChain

Inherited from

MockCUIListBoxItem.constructor

Methods

GetHeight()

ts
GetHeight(): number;

Returns

number

Window height.

Implementation of

ts
CUIListBoxItemMsgChain.GetHeight

Inherited from

MockCUIListBoxItem.GetHeight


GetWidth()

ts
GetWidth(): number;

Returns

number

Window width.

Implementation of

ts
CUIListBoxItemMsgChain.GetWidth

Inherited from

MockCUIListBoxItem.GetWidth


OnKeyboard()

ts
OnKeyboard(): boolean;

Returns

boolean

Inherited from

MockCUIListBoxItem.OnKeyboard


Show()

ts
Show(isShown: boolean): void;

Show or hide the window.

Parameters

ParameterType
isShownboolean

Returns

void

Remarks

Visibility does not attach, detach, enable, or disable the window.

Implementation of

ts
CUIListBoxItemMsgChain.Show

Inherited from

MockCUIListBoxItem.Show


create()

ts
static create(): MockCUIListBoxItemMsgChain;

Returns

MockCUIListBoxItemMsgChain

Overrides

MockCUIListBoxItem.create


mock()

ts
static mock(): CUIListBoxItemMsgChain;

Returns

CUIListBoxItemMsgChain

Overrides

MockCUIListBoxItem.mock

Properties

AddIconField

ts
AddIconField: Mock<(_value?: number) => CUIStatic>;

Add an icon field to the item.

Param

value

Field width.

Returns

Created static field.

Implementation of

ts
CUIListBoxItemMsgChain.AddIconField

Inherited from

MockCUIListBoxItem.AddIconField


AddTextField

ts
AddTextField: Mock<(text: string, _width?: number) => CUITextWnd>;

Add a text field to the item.

Param

text

Field text.

Param

width

Field width.

Returns

Created text window.

Implementation of

ts
CUIListBoxItemMsgChain.AddTextField

Inherited from

MockCUIListBoxItem.AddTextField


AttachChild

ts
AttachChild: Mock<(window: CUIWindow) => void>;

Attach a child window.

Remarks

The Lua binding adopts child; after attachment, treat the parent as owning its lifetime.

Param

child

Child window.

Implementation of

ts
CUIListBoxItemMsgChain.AttachChild

Inherited from

MockCUIListBoxItem.AttachChild


children

ts
children: CUIWindow[] = [];

Inherited from

MockCUIListBoxItem.children


DetachChild

ts
DetachChild: Mock<(window: CUIWindow) => void>;

Detach a child window.

Remarks

Detaching removes the parent relation. It does not reinitialize the window or attach it elsewhere.

Param

child

Child window.

Implementation of

ts
CUIListBoxItemMsgChain.DetachChild

Inherited from

MockCUIListBoxItem.DetachChild


Enable

ts
Enable: Mock<(isEnabled: boolean) => void>;

Enable or disable interaction.

Remarks

Enabled state and visibility are separate. Hidden controls can still be enabled.

Param

is_enabled

Whether the window should be enabled.

Implementation of

ts
CUIListBoxItemMsgChain.Enable

Inherited from

MockCUIListBoxItem.Enable


focusReceiveTime

ts
focusReceiveTime: number = 0;

Inherited from

MockCUIListBoxItem.focusReceiveTime


FocusReceiveTime

ts
FocusReceiveTime: Mock<() => number>;

Returns

Level time when this window received focus.

Implementation of

ts
CUIListBoxItemMsgChain.FocusReceiveTime

Inherited from

MockCUIListBoxItem.FocusReceiveTime


GetAbsoluteRect

ts
GetAbsoluteRect: Mock<() => Frect>;

Returns

Window rectangle in screen coordinates.

Implementation of

ts
CUIListBoxItemMsgChain.GetAbsoluteRect

Inherited from

MockCUIListBoxItem.GetAbsoluteRect


GetFont

ts
GetFont: Mock<() => CGameFont>;

Get the font assigned to this window.

Remarks

Text controls need a font assigned before drawing custom text reliably.

Returns

Font assigned to this window.

Implementation of

ts
CUIListBoxItemMsgChain.GetFont

Inherited from

MockCUIListBoxItem.GetFont


GetMouseX

ts
GetMouseX: Mock<() => number>;

Get cursor X coordinate stored on this window.

Since

OpenXRay 2026-01-01, e3b0e3c5, PR #2028

Source

src/xrUICore/ui_export_script.cpp, CUIWindow.GetMouseX binding.

Returns

Current cursor X coordinate.

Implementation of

ts
CUIListBoxItemMsgChain.GetMouseX

Inherited from

MockCUIListBoxItem.GetMouseX


GetMouseY

ts
GetMouseY: Mock<() => number>;

Get cursor Y coordinate stored on this window.

Since

OpenXRay 2026-01-01, e3b0e3c5, PR #2028

Source

src/xrUICore/ui_export_script.cpp, CUIWindow.GetMouseY binding.

Returns

Current cursor Y coordinate.

Implementation of

ts
CUIListBoxItemMsgChain.GetMouseY

Inherited from

MockCUIListBoxItem.GetMouseY


GetTextItem

ts
GetTextItem: Mock<() => CUITextWnd>;

Returns

Main text item.

Implementation of

ts
CUIListBoxItemMsgChain.GetTextItem

Inherited from

MockCUIListBoxItem.GetTextItem


GetWndPos

ts
GetWndPos: Mock<() => vector2>;

Returns

Window position relative to its parent.

Implementation of

ts
CUIListBoxItemMsgChain.GetWndPos

Inherited from

MockCUIListBoxItem.GetWndPos


iconItem?

ts
optional iconItem?: CUIStatic;

Inherited from

MockCUIListBoxItem.iconItem


Init

ts
Init: Mock<(rectOrX: number | Frect, y?: number, width?: number, height?: number) => void>;

Initialize window rectangle.

Param

frect

Window rectangle.

Implementation of

ts
CUIListBoxItemMsgChain.Init

Inherited from

MockCUIListBoxItem.Init


isAutoDelete

ts
isAutoDelete: boolean = false;

Inherited from

MockCUIListBoxItem.isAutoDelete


IsAutoDelete

ts
IsAutoDelete: Mock<() => boolean>;

Returns

Whether the engine owns and deletes this window with its parent.

Implementation of

ts
CUIListBoxItemMsgChain.IsAutoDelete

Inherited from

MockCUIListBoxItem.IsAutoDelete


IsCursorOverWindow

ts
IsCursorOverWindow: Mock<() => boolean>;

Returns

Whether the UI cursor is currently over this window.

Implementation of

ts
CUIListBoxItemMsgChain.IsCursorOverWindow

Inherited from

MockCUIListBoxItem.IsCursorOverWindow


isEnabled

ts
isEnabled: boolean = false;

Inherited from

MockCUIListBoxItem.isEnabled


IsEnabled

ts
IsEnabled: Mock<() => boolean>;

Returns

Whether the window accepts interaction.

Implementation of

ts
CUIListBoxItemMsgChain.IsEnabled

Inherited from

MockCUIListBoxItem.IsEnabled


isPostProcessMode

ts
isPostProcessMode: boolean = false;

Inherited from

MockCUIListBoxItem.isPostProcessMode


isShown

ts
isShown: boolean = false;

Inherited from

MockCUIListBoxItem.isShown


IsShown

ts
IsShown: Mock<() => boolean>;

Returns

Whether the window is visible.

Implementation of

ts
CUIListBoxItemMsgChain.IsShown

Inherited from

MockCUIListBoxItem.IsShown


mouseX

ts
mouseX: number = 0;

Inherited from

MockCUIListBoxItem.mouseX


mouseY

ts
mouseY: number = 0;

Inherited from

MockCUIListBoxItem.mouseY


ResetPPMode

ts
ResetPPMode: Mock<() => void>;

Disable post-process mode for this window.

Remarks

Pair with CUIWindow.SetPPMode when a window no longer needs post-process rendering.

Implementation of

ts
CUIListBoxItemMsgChain.ResetPPMode

Inherited from

MockCUIListBoxItem.ResetPPMode


SetAutoDelete

ts
SetAutoDelete: Mock<(isAutoDelete: boolean) => void>;

Set whether the parent owns this child window.

Remarks

Use this for script-created windows that are attached to a parent and should be cleaned up with the UI tree.

Param

auto_delete

Whether the engine should delete the child automatically.

Implementation of

ts
CUIListBoxItemMsgChain.SetAutoDelete

Inherited from

MockCUIListBoxItem.SetAutoDelete


SetColor

ts
SetColor: Mock<UnknownFunction>;

Set frame line color.

Param

color

ARGB color.

Implementation of

ts
CUIListBoxItemMsgChain.SetColor

Inherited from

MockCUIListBoxItem.SetColor


SetFont

ts
SetFont: Mock<(font: CGameFont) => void>;

Set the font used by this window.

Param

font

Font object.

Implementation of

ts
CUIListBoxItemMsgChain.SetFont

Inherited from

MockCUIListBoxItem.SetFont


SetHeight

ts
SetHeight: Mock<(height: number) => void>;

Set window height.

Param

height

New height.

Implementation of

ts
CUIListBoxItemMsgChain.SetHeight

Inherited from

MockCUIListBoxItem.SetHeight


SetPPMode

ts
SetPPMode: Mock<() => void>;

Enable post-process mode for this window.

Remarks

Use for windows meant to be drawn through the post-process UI path, and reset it when the window returns to normal UI rendering.

Implementation of

ts
CUIListBoxItemMsgChain.SetPPMode

Inherited from

MockCUIListBoxItem.SetPPMode


SetTextColor

ts
SetTextColor: Mock<UnknownFunction>;

Set item text color.

Param

color

ARGB color.

Implementation of

ts
CUIListBoxItemMsgChain.SetTextColor

Inherited from

MockCUIListBoxItem.SetTextColor


SetWidth

ts
SetWidth: Mock<(width: number) => void>;

Set window width.

Param

width

New width.

Implementation of

ts
CUIListBoxItemMsgChain.SetWidth

Inherited from

MockCUIListBoxItem.SetWidth


SetWindowName

ts
SetWindowName: Mock<(name: string) => void>;

Set debug/window name.

Param

name

Window name.

Implementation of

ts
CUIListBoxItemMsgChain.SetWindowName

Inherited from

MockCUIListBoxItem.SetWindowName


SetWndPos

ts
SetWndPos: Mock<(positionOrX: number | vector2, y?: number) => void>;

Set window position.

Param

vector2

New position.

Implementation of

ts
CUIListBoxItemMsgChain.SetWndPos

Inherited from

MockCUIListBoxItem.SetWndPos


SetWndRect

ts
SetWndRect: Mock<(rectOrX: number | Frect, y?: number, width?: number, height?: number) => void>;

Set window rectangle.

Param

rect

New rectangle.

Implementation of

ts
CUIListBoxItemMsgChain.SetWndRect

Inherited from

MockCUIListBoxItem.SetWndRect


SetWndSize

ts
SetWndSize: Mock<(sizeOrWidth: number | vector2, height?: number) => void>;

Set window size.

Param

vector2

New size.

Implementation of

ts
CUIListBoxItemMsgChain.SetWndSize

Inherited from

MockCUIListBoxItem.SetWndSize


textField?

ts
optional textField?: CUITextWnd;

Inherited from

MockCUIListBoxItem.textField


textItem

ts
textItem: CUITextWnd;

Inherited from

MockCUIListBoxItem.textItem


windowFont

ts
windowFont: CGameFont | null = null;

Inherited from

MockCUIListBoxItem.windowFont


windowName

ts
windowName: string | null = null;

Inherited from

MockCUIListBoxItem.windowName


WindowName

ts
WindowName: Mock<() => string>;

Returns

Window name.

Implementation of

ts
CUIListBoxItemMsgChain.WindowName

Inherited from

MockCUIListBoxItem.WindowName


windowPosition

ts
windowPosition: vector2;

Inherited from

MockCUIListBoxItem.windowPosition


windowRect

ts
windowRect: Frect | null = null;

Inherited from

MockCUIListBoxItem.windowRect


windowSize

ts
windowSize: vector2;

Inherited from

MockCUIListBoxItem.windowSize