UFO: Alien Invasion
Loading...
Searching...
No Matches
uiWindowNode Class Reference

#include <ui_node_window.h>

Inheritance diagram for uiWindowNode:
Inheritance graph
Collaboration diagram for uiWindowNode:
Collaboration graph

Public Member Functions

void setFill (uiNode_t *node, bool value)
Public Member Functions inherited from uiLocatedNode
virtual void drawTooltip (const uiNode_t *node, int x, int y) const
virtual void drawOverWindow (uiNode_t *node)
virtual void onLeftClick (uiNode_t *node, int x, int y)
virtual void onRightClick (uiNode_t *node, int x, int y)
virtual void onMiddleClick (uiNode_t *node, int x, int y)
virtual bool onScroll (uiNode_t *node, int deltaX, int deltaY)
virtual void onMouseMove (uiNode_t *node, int x, int y)
virtual void onMouseDown (uiNode_t *node, int x, int y, int button)
virtual void onMouseUp (uiNode_t *node, int x, int y, int button)
virtual bool onMouseLongPress (uiNode_t *node, int x, int y, int button)
 Send mouse event when a pressed mouse button is dragged.
virtual void onMouseEnter (uiNode_t *node)
virtual void onMouseLeave (uiNode_t *node)
virtual void onCapturedMouseMove (uiNode_t *node, int x, int y)
virtual void onCapturedMouseLost (uiNode_t *node)
virtual bool onStartDragging (uiNode_t *node, int startX, int startY, int currentX, int currentY, int button)
 Send mouse event when a pressed mouse button is dragged.
virtual bool onDndEnter (uiNode_t *node)
virtual bool onDndMove (uiNode_t *node, int x, int y)
virtual void onDndLeave (uiNode_t *node)
virtual bool onDndDrop (uiNode_t *node, int x, int y)
virtual bool onDndFinished (uiNode_t *node, bool isDropped)
virtual void onFocusGained (uiNode_t *node)
virtual void onFocusLost (uiNode_t *node)
virtual bool onKeyPressed (uiNode_t *node, unsigned int key, unsigned short unicode)
virtual bool onKeyReleased (uiNode_t *node, unsigned int key, unsigned short unicode)
virtual void getClientPosition (uiNode_t const *node, vec2_t position)
virtual int getCellWidth (uiNode_t *node)
virtual int getCellHeight (uiNode_t *node)
Public Member Functions inherited from uiNode
virtual void initNodeDynamic (uiNode_t *node)
virtual void onActivate (uiNode_t *node)
 Activate the node. Can be used without the mouse (ie. a button will execute onClick).
virtual void onPropertyChanged (uiNode_t *node, const value_t *property)
virtual ~uiNode ()

Private Member Functions

void draw (uiNode_t *node) override
void initNode (uiNode_t *node) override
void deleteNode (uiNode_t *node) override
 Actions to do on deleting the node.
void doLayout (uiNode_t *node) override
 Call to update the node layout. This common code revalidates the node tree.
void onLoading (uiNode_t *node) override
 Called at the begin of the load from script.
void onLoaded (uiNode_t *node) override
 Called at the end of the load from script.
void onWindowOpened (uiNode_t *node, linkedList_t *params) override
 Called when we init the node on the screen.
void onWindowClosed (uiNode_t *node) override
 Called when we close the node on the screen.
void onWindowActivate (uiNode_t *node) override
 Called when a windows gets active again after some other window was popped from the stack.
void onSizeChanged (uiNode_t *node) override
 Callback stub.
void clone (uiNode_t const *source, uiNode_t *clone) override

Detailed Description

Definition at line 36 of file ui_node_window.h.

Member Function Documentation

◆ clone()

void uiWindowNode::clone ( uiNode_t const * source,
uiNode_t * clone )
overrideprivatevirtual

call to initialize a cloned node

Reimplemented from uiNode.

Definition at line 395 of file ui_node_window.cpp.

References uiNode::clone(), clone(), EXTRADATA, and OBJZERO.

Referenced by clone().

◆ deleteNode()

void uiWindowNode::deleteNode ( uiNode_t * node)
overrideprivatevirtual

Actions to do on deleting the node.

Parameters
[in,out]nodePointer to the node to destroy

Reimplemented from uiNode.

Definition at line 179 of file ui_node_window.cpp.

References uiNode::deleteNode(), and UI_RemoveWindow().

◆ doLayout()

void uiWindowNode::doLayout ( uiNode_t * node)
overrideprivatevirtual

Call to update the node layout. This common code revalidates the node tree.

Called to update node layout

Todo
check and fix here window outside the screen

Reimplemented from uiLocatedNode.

Definition at line 185 of file ui_node_window.cpp.

References uiNode_t::box, CONTROLS_PADDING, uiLocatedNode::doLayout(), EXTRADATA, int(), uiNode_t::invalidated, uiBox_t::pos, uiBox_t::size, UI_FindNode(), UI_StarLayout(), UI_WindowIsFullScreen(), viddef, WINDOW_CLOSE_BUTTON_NAME, and WINDOW_DRAG_BUTTON_NAME.

◆ draw()

void uiWindowNode::draw ( uiNode_t * node)
overrideprivatevirtual

◆ initNode()

void uiWindowNode::initNode ( uiNode_t * node)
overrideprivatevirtual

call to initialize the node structure and extradata structure

Reimplemented from uiNode.

Definition at line 167 of file ui_node_window.cpp.

References EXTRADATA, and uiNode::initNode().

◆ onLoaded()

void uiWindowNode::onLoaded ( uiNode_t * node)
overrideprivatevirtual

Called at the end of the load from script.

Reimplemented from uiNode.

Definition at line 375 of file ui_node_window.cpp.

References EXTRADATA, UI_Invalidate(), UI_Window_FlagFullscreen(), UI_Window_SetCloseButton(), and UI_Window_SetDragButton().

◆ onLoading()

void uiWindowNode::onLoading ( uiNode_t * node)
overrideprivatevirtual

Called at the begin of the load from script.

Reimplemented from uiNode.

Definition at line 291 of file ui_node_window.cpp.

References uiNode_t::box, EXTRADATA, uiNode_t::font, uiNode_t::padding, uiBox_t::size, VID_NORM_HEIGHT, VID_NORM_WIDTH, viddef, and WINDOW_FONT_BIG.

◆ onSizeChanged()

void uiWindowNode::onSizeChanged ( uiNode_t * node)
overrideprivatevirtual

Callback stub.

Called when the node size change

Reimplemented from uiLocatedNode.

Definition at line 277 of file ui_node_window.cpp.

References uiNode_t::box, EXTRADATA, uiNode::onWindowActivate(), uiBox_t::size, UI_Window_FlagFullscreen(), and viddef.

Referenced by setFill().

◆ onWindowActivate()

void uiWindowNode::onWindowActivate ( uiNode_t * node)
overrideprivatevirtual

Called when a windows gets active again after some other window was popped from the stack.

Reimplemented from uiNode.

Definition at line 264 of file ui_node_window.cpp.

References EXTRADATA, uiNode::onWindowActivate(), onWindowActivate(), UI_ExecuteEventActions(), and UI_ExecuteLuaEventScript().

Referenced by onWindowActivate().

◆ onWindowClosed()

void uiWindowNode::onWindowClosed ( uiNode_t * node)
overrideprivatevirtual

Called when we close the node on the screen.

Reimplemented from uiNode.

Definition at line 248 of file ui_node_window.cpp.

References EXTRADATA, uiNode::onWindowClosed(), onWindowClosed(), UI_ExecuteEventActions(), and UI_ExecuteLuaEventScript().

Referenced by onWindowClosed().

◆ onWindowOpened()

void uiWindowNode::onWindowOpened ( uiNode_t * node,
linkedList_t * params )
overrideprivatevirtual

Called when we init the node on the screen.

Reimplemented from uiNode.

Definition at line 230 of file ui_node_window.cpp.

References EXTRADATA, uiNode::onWindowOpened(), onWindowOpened(), UI_ExecuteEventActionsEx(), UI_ExecuteLuaEventScript_ParamList(), and UI_Invalidate().

Referenced by onWindowOpened().

◆ setFill()

void uiWindowNode::setFill ( uiNode_t * node,
bool value )

Definition at line 469 of file ui_node_window.cpp.

References onSizeChanged(), and UI_EXTRADATA.

Referenced by uiWindowNode_t_set_fill().


The documentation for this class was generated from the following files: