27 #include "../../shared/ufotypes.h"
28 #include "../../common/scripts.h"
29 #include "../../common/scripts_lua.h"
34 struct nodeKeyBinding_s;
38 struct uiLuaCallback_t;
184 #define UI_EXTRADATA_POINTER(NODE, TYPE) ((TYPE*)((char*)NODE + sizeof(uiNode_t)))
185 #define UI_EXTRADATA(NODE, TYPE) (*UI_EXTRADATA_POINTER(NODE, TYPE))
186 #define UI_EXTRADATACONST_POINTER(NODE, TYPE) ((TYPE*)((const char*)NODE + sizeof(uiNode_t)))
187 #define UI_EXTRADATACONST(NODE, TYPE) (*UI_EXTRADATACONST_POINTER(NODE, const TYPE))
struct uiAction_s * onWheelDown
const char * UI_GetPath(const uiNode_t *node) __attribute__((warn_unused_result))
Return a path from a window to a node.
QGL_EXTERN GLint GLenum type
struct uiAction_s * onChange
struct uiAction_s * onMouseEnter
int LUA_EVENT
holds a reference to a lua event handler
uiNode_t * UI_CloneNode(const uiNode_t *node, uiNode_t *newWindow, bool recursive, const char *newName, bool isDynamic) __attribute__((warn_unused_result))
Clone a node.
uiBehaviour_t * behaviour
int UI_GetNodeBehaviourCount(void) __attribute__((warn_unused_result))
struct uiAction_s * onMouseLeave
LUA_EVENT lua_onKeyPressed
uiExcludeRect_t * firstExcludeRect
void UI_ReadNodePath(const char *path, const uiNode_t *relativeNode, const uiNode_t *iterationNode, uiNode_t **resultNode, const value_t **resultProperty, value_t *luaMethod=nullptr)
Read a path and return every we can use (node and property)
void alignBox(uiBox_t &inner, align_t direction)
LUA_EVENT lua_onWheelDown
struct uiAction_s * onClick
LUA_EVENT lua_onMouseLeave
struct uiExcludeRect_s uiExcludeRect_t
void UI_DeleteNode(uiNode_t *node)
LUA_EVENT lua_onMiddleClick
The hash table structure, contains an array of buckets being indexed by the hash function.
uiNode_t * UI_AllocNode(const char *name, const char *type, bool isDynamic)
Allocate a node into the UI memory.
void UI_DeleteAllChild(uiNode_t *node)
Remove all child from a node (only remove dynamic memory allocation nodes)
align_t
We need this here for checking the boundaries from script values.
LUA_EVENT lua_onRightClick
bool UI_CheckVisibility(uiNode_t *node)
Check the if conditions for a given node.
LUA_EVENT lua_onFocusGained
struct uiAction_s * onWheelUp
struct uiAction_s * onMiddleClick
LUA_EVENT lua_onDragDropDrop
uiNode_t * UI_GetNodeByPath(const char *path) __attribute__((warn_unused_result))
Return a node by a path name (names with dot separation) It is a simplification facade over UI_ReadNo...
LUA_EVENT lua_onKeyReleased
Atomic structure used to define most of the UI.
uiBehaviour_t * UI_GetNodeBehaviour(const char *name) __attribute__((warn_unused_result))
Return a node behaviour by name.
Contain the context of the calling of a function.
struct uiAction_s * onRightClick
hashTable_s * nodeMethods
LUA_EVENT lua_onDragDropEnter
struct uiAction_s * visibilityCondition
node behaviour, how a node work
LUA_EVENT lua_onVisibleWhen
QGL_EXTERN GLuint GLsizei GLsizei GLint GLenum GLchar * name
struct uiAction_s * onWheel
uiNode_t * UI_GetNodeAtPosition(int x, int y) __attribute__((warn_unused_result))
Return the first visible node at a position.
#define Vector2Copy(src, dest)
LUA_EVENT lua_onMouseEnter
uiBehaviour_t * UI_GetNodeBehaviourByIndex(int index) __attribute__((warn_unused_result))
LUA_EVENT lua_onDragDropMove
LUA_EVENT lua_onFocusLost
Model that have more than one part (top and down part of an aircraft)
LUA_EVENT lua_onDragDropLeave
struct uiExcludeRect_s * next
Atomic element to store UI scripts The parser use this atom to translate script action into many tree...
void set(vec2_t pos, vec2_t size)
struct uiKeyBinding_s * key
LUA_EVENT lua_onDragDropFinished