Types
MENU_ITEM_TYPE

Menu item types

MENU_ACTION

Menu item actions

MENU_INPUT_TYPE

Menu input value

MENU_EVENT_CALLBACK

Menu event callback

Macros
MENU_FLAG_DIRTY

Menu item actions

Functions
Menu_Initialize
void Menu_Initialize(
const Menu* menus
)

Initialize all the menu pages Must be called first (will reset or set default callback)

Parameters
menus
const Menu*

Table of <Menu> structures that discribe all the menu pages

Menu_SetInputCallback
inline void Menu_SetInputCallback(
Menu_InputCB cb
)

Set the callback function to be called to handle menu input

Parameters
cb
Menu_InputCB

Callback function address

Menu_SetDrawCallback
inline void Menu_SetDrawCallback(
Menu_DrawCB cb
)

Set the callback function to be called to handle menu item drawing

Parameters
cb
Menu_DrawCB

Callback function address

Menu_SetEventCallback
inline void Menu_SetEventCallback(
Menu_EventCB cb
)

Set the callback function to be called when event occurs

Parameters
cb
Menu_EventCB

Callback function address

Menu_SetDirty
inline void Menu_SetDirty()

Set flag to force a whole menu redraw

Menu_DrawPage
void Menu_DrawPage(
u8 page
)

Draw a given page by its page number

Parameters
page
u8

Page index to draw (index is relative to the ist passed to Menu_Initialize function)

Menu_Update
void Menu_Update()

Update the menu handler

Menu_SetScreenWidth
inline void Menu_SetScreenWidth(
u8 width
)

Set menu screen with

Parameters
width
u8

Screen width in screen mode's unit (tiles or pixels)

Menu_GetScreenWidth
inline u8 Menu_GetScreenWidth()

Get menu screen with

Return: Screen width in screen mode's unit (tiles or pixels)