ui_node_window.h File Reference

#include "../../../shared/mathlib.h"
Include dependency graph for ui_node_window.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  node_index_s
struct  windowExtraData_t
 extradata for the window node More...

Defines

#define INDEXEDCHILD_HASH_SIZE   32

Typedefs

typedef struct node_index_s node_index_t

Functions

void UI_RegisterWindowNode (struct uiBehaviour_s *behaviour)
qboolean UI_WindowIsFullScreen (const struct uiNode_s *const window)
qboolean UI_WindowIsDropDown (const struct uiNode_s *const window)
 True if the window is a drop down.
qboolean UI_WindowIsModal (const struct uiNode_s *const window)
 True if the window is a modal.
void UI_WindowNodeRegisterKeyBinding (struct uiNode_s *window, struct uiKeyBinding_s *binding)
 Add a key binding to a window node. Window node store key bindings for his node child.
struct uiKeyBinding_sUI_WindowNodeGetKeyBinding (const struct uiNode_s *const node, unsigned int key)
 Search a a key binding from a window node. Window node store key bindings for his node child.
void UI_WindowNodeSetRenderNode (struct uiNode_s *node, struct uiNode_s *renderNode)
vec_tUI_WindowNodeGetNoticePosition (struct uiNode_s *node)
 Get the noticePosition from a window node.
struct uiNode_sUI_WindowNodeGetIndexedChild (struct uiNode_s *const node, const char *childName)
 Get a node from child index.
qboolean UI_WindowNodeAddIndexedNode (struct uiNode_s *const node, struct uiNode_s *const child)
 Add a node to the child index.
qboolean UI_WindowNodeRemoveIndexedNode (struct uiNode_s *const node, struct uiNode_s *const child)
 Remove a node from the child index.

Variables

struct uiBehaviour_s const * ui_windowBehaviour

Detailed Description

Definition in file ui_node_window.h.


Define Documentation

#define INDEXEDCHILD_HASH_SIZE   32

Typedef Documentation

typedef struct node_index_s node_index_t

Function Documentation

void UI_RegisterWindowNode ( struct uiBehaviour_s behaviour  ) 
qboolean UI_WindowIsDropDown ( const struct uiNode_s *const   node  ) 

True if the window is a drop down.

Parameters:
node A window node
Returns:
True if the window is a drop down.

Definition at line 419 of file ui_node_window.c.

References EXTRADATACONST.

Referenced by UI_GetNodeAtPosition(), and UI_LeftClick().

qboolean UI_WindowIsFullScreen ( const struct uiNode_s *const   window  ) 
qboolean UI_WindowIsModal ( const struct uiNode_s *const   node  ) 

True if the window is a modal.

Parameters:
node A window node
Returns:
True if the window is a modal.

Definition at line 429 of file ui_node_window.c.

References EXTRADATACONST.

Referenced by UI_GetNodeAtPosition(), and UI_KeyPressed().

qboolean UI_WindowNodeAddIndexedNode ( struct uiNode_s *const   node,
struct uiNode_s *const   child 
)

Add a node to the child index.

Todo:
display a warning, we must not override a node name here

Definition at line 90 of file ui_node_window.c.

References Com_HashKey(), EXTRADATA, hash(), node_index_s::hash_next, INDEXEDCHILD_HASH_SIZE, Mem_PoolAlloc, uiNode_s::name, node_index_s::next, node_index_s::node, qfalse, and ui_sysPool.

Referenced by UI_InsertNode().

struct uiNode_s* UI_WindowNodeGetIndexedChild ( uiNode_t *const   node,
const char *  childName 
) [read]

Get a node from child index.

Returns:
A child node by his name, else NULL

Definition at line 73 of file ui_node_window.c.

References Com_HashKey(), EXTRADATA, hash(), node_index_s::hash_next, INDEXEDCHILD_HASH_SIZE, uiNode_s::name, and node_index_s::node.

Referenced by UI_ReadNodePath().

struct uiKeyBinding_s* UI_WindowNodeGetKeyBinding ( const struct uiNode_s *const   node,
unsigned int  key 
) [read]

Search a a key binding from a window node. Window node store key bindings for his node child.

Parameters:
node A window node
key A key code, either K_ value or lowercase ascii

Definition at line 456 of file ui_node_window.c.

References EXTRADATACONST, uiKeyBinding_s::key, uiKeyBinding_s::next, and UI_NodeInstanceOf().

Referenced by UI_KeyPressedInWindow().

vec_t* UI_WindowNodeGetNoticePosition ( struct uiNode_s node  ) 

Get the noticePosition from a window node.

Parameters:
node A window node
Returns:
A position, else NULL if no notice position

Definition at line 407 of file ui_node_window.c.

References EXTRADATA.

Referenced by UI_DrawNotice().

void UI_WindowNodeRegisterKeyBinding ( uiNode_t node,
uiKeyBinding_t binding 
)

Add a key binding to a window node. Window node store key bindings for his node child.

Parameters:
node A window node
binding Key binding to link with the window (structure should not be already linked somewhere)
Todo:
Rework that function to remove possible wrong use of that function

Definition at line 441 of file ui_node_window.c.

References EXTRADATA, uiKeyBinding_s::next, and UI_NodeInstanceOf().

Referenced by UI_SetKeyBinding().

qboolean UI_WindowNodeRemoveIndexedNode ( struct uiNode_s *const   node,
struct uiNode_s *const   child 
)

Remove a node from the child index.

FIXME implement it

Definition at line 117 of file ui_node_window.c.

References qfalse.

Referenced by UI_RemoveNode().

void UI_WindowNodeSetRenderNode ( struct uiNode_s node,
struct uiNode_s renderNode 
)

Definition at line 276 of file ui_node_window.c.

References Com_Printf(), EXTRADATA, UI_GetPath(), and UI_NodeInstanceOf().

Referenced by UI_ZoneNodeLoaded().


Variable Documentation

Definition at line 54 of file ui_node_window.c.

Referenced by UI_ReadNodePath().


Generated by  doxygen 1.6.2