ui_node_optionlist.c File Reference

#include "../ui_main.h"
#include "../ui_parse.h"
#include "../ui_actions.h"
#include "../ui_font.h"
#include "../ui_icon.h"
#include "../ui_render.h"
#include "ui_node_abstractoption.h"
#include "ui_node_abstractnode.h"
#include "ui_node_optionlist.h"
#include "ui_node_panel.h"
#include "ui_node_option.h"
#include "../../client.h"
Include dependency graph for ui_node_optionlist.c:

Go to the source code of this file.

Defines

#define EXTRADATA(node)   UI_EXTRADATA(node, abstractOptionExtraData_t)
#define CORNER_SIZE   25
#define MID_SIZE   1
#define MARGE   3

Functions

static void UI_OptionListNodeUpdateScroll (uiNode_t *node)
 Update the scroll according to the number of items and the size of the node.
static void UI_OptionListNodeDraw (uiNode_t *node)
static uiNode_tUI_OptionListNodeGetOptionAtPosition (uiNode_t *node, int x, int y)
static void UI_OptionListNodeClick (uiNode_t *node, int x, int y)
 Handles selectboxes clicks.
static void UI_OptionListNodeMouseWheel (uiNode_t *node, qboolean down, int x, int y)
 Auto scroll the list.
static void UI_OptionListNodeLoading (uiNode_t *node)
 Called before loading. Used to set default attribute values.
static void UI_OptionListNodeLoaded (uiNode_t *node)
void UI_RegisterOptionListNode (uiBehaviour_t *behaviour)

Detailed Description

Todo:
manage disabled option

Definition in file ui_node_optionlist.c.


Define Documentation

#define CORNER_SIZE   25

Definition at line 42 of file ui_node_optionlist.c.

#define EXTRADATA ( node   )     UI_EXTRADATA(node, abstractOptionExtraData_t)

Definition at line 40 of file ui_node_optionlist.c.

#define MARGE   3

Definition at line 44 of file ui_node_optionlist.c.

#define MID_SIZE   1

Definition at line 43 of file ui_node_optionlist.c.


Function Documentation

static void UI_OptionListNodeClick ( uiNode_t node,
int  x,
int  y 
) [static]
static void UI_OptionListNodeDraw ( uiNode_t node  )  [static]
static uiNode_t* UI_OptionListNodeGetOptionAtPosition ( uiNode_t node,
int  x,
int  y 
) [static]
static void UI_OptionListNodeLoaded ( uiNode_t node  )  [static]

Definition at line 245 of file ui_node_optionlist.c.

Referenced by UI_RegisterOptionListNode().

static void UI_OptionListNodeLoading ( uiNode_t node  )  [static]

Called before loading. Used to set default attribute values.

Definition at line 238 of file ui_node_optionlist.c.

References uiNode_s::color, EXTRADATA, uiNode_s::padding, and Vector4Set.

Referenced by UI_RegisterOptionListNode().

static void UI_OptionListNodeMouseWheel ( uiNode_t node,
qboolean  down,
int  x,
int  y 
) [static]
static void UI_OptionListNodeUpdateScroll ( uiNode_t node  )  [static]

Update the scroll according to the number of items and the size of the node.

Definition at line 50 of file ui_node_optionlist.c.

References count, EXTRADATA, uiNode_s::padding, uiNode_s::size, UI_ExecuteEventActions(), UI_FontGetHeight(), UI_GetFontFromNode(), and UI_SetScroll().

Referenced by UI_OptionListNodeDraw().

void UI_RegisterOptionListNode ( uiBehaviour_t behaviour  ) 

Generated by  doxygen 1.6.2