UFO: Alien Invasion
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
uiTimer_s Struct Reference

#include <ui_timer.h>

Data Fields

struct uiTimer_snext
 
struct uiTimer_sprev
 
int nextTime
 
uiNode_towner
 
timerCallback_t callback
 
int calledTime
 
int delay
 
voiduserData
 
bool isRunning
 

Detailed Description

Todo:
We can use void* for the owner type, and allow to use it outside nodes

Definition at line 36 of file ui_timer.h.

Field Documentation

timerCallback_t uiTimer_s::callback

function called every delay

Definition at line 42 of file ui_timer.h.

Referenced by UI_AllocTimer(), UI_HandleTimers(), and UI_TimerRelease().

int uiTimer_s::calledTime

time we call the function. For the first call the value is 1

Definition at line 43 of file ui_timer.h.

Referenced by CL_BattlescapeRadarGenerateAll(), uiSpinnerNode::repeat(), UI_AllocTimer(), UI_HandleTimers(), and UI_VScrollbarNodeRepeat().

int uiTimer_s::delay

delay in millisecond between each call of

Definition at line 45 of file ui_timer.h.

Referenced by uiSpinnerNode::repeat(), UI_AllocTimer(), UI_HandleTimers(), UI_TimerStart(), and UI_VScrollbarNodeRepeat().

bool uiTimer_s::isRunning

true if the timer is running

Definition at line 47 of file ui_timer.h.

Referenced by UI_AllocTimer(), UI_Draw(), UI_HandleTimers(), UI_TimerStart(), and UI_TimerStop().

struct uiTimer_s* uiTimer_s::next

next timer in the ordered list of active timers

Definition at line 37 of file ui_timer.h.

Referenced by TEST_F(), UI_AllocTimer(), UI_HandleTimers(), UI_InsertTimerInActiveList(), UI_RemoveTimerFromActiveList(), UI_TimerRelease(), UI_TimerStart(), and UI_TimerStop().

int uiTimer_s::nextTime

next time we must call the callback function. Must node be edited, it used to sort linkedlist of timers

Definition at line 39 of file ui_timer.h.

Referenced by UI_HandleTimers(), UI_InsertTimerInActiveList(), and UI_TimerStart().

uiNode_t* uiTimer_s::owner

owner node of the timer

Definition at line 41 of file ui_timer.h.

Referenced by TEST_F(), UI_AllocTimer(), UI_HandleTimers(), and UI_TimerRelease().

struct uiTimer_s* uiTimer_s::prev

previous timer in the ordered list of active timers

Definition at line 38 of file ui_timer.h.

Referenced by UI_AllocTimer(), UI_InsertTimerInActiveList(), UI_RemoveTimerFromActiveList(), UI_TimerRelease(), UI_TimerStart(), and UI_TimerStop().

void* uiTimer_s::userData

free to use data, not used by the core functions

Definition at line 46 of file ui_timer.h.


The documentation for this struct was generated from the following file: