menu.c File Reference

General management for menu, dialog boxes ... More...

Go to the source code of this file.

Functions

enum MENU_code MENU_Quit (void)
void MENU_SetTextColor (color_t TxtColor)
color_t MENU_GetTextColor (void)
void MENU_SetBGndColor (color_t BGndColor)
color_t MENU_GetBGndColor (void)
void MENU_Remove (void)
void MENU_Set (tMenu *mptr)
void MENU_Question (const u8 *str, bool *answer)
void MENU_ClearCurrentCommand (void)
void MENU_ClearCurrentMenu (void)
void MENU_Print (const u8 *str)
void MENU_SetAppliDivider (divider_t divider)
void MENU_RestoreAppliDivider (void)

Detailed Description

Author:
FL
Date:
07/2007
10/2008
Version:
3.0 Add Primer 2 and ST library v2.0.3
4.0 Add Open4 Primer
Date:
10/2009

Definition in file menu.c.


Function Documentation

void MENU_ClearCurrentCommand ( void   ) 

Set CurrentCommand to 0.

Definition at line 966 of file menu.c.

void MENU_ClearCurrentMenu ( void   ) 

Set CurrentMenu to 0

Definition at line 982 of file menu.c.

color_t MENU_GetBGndColor ( void   ) 

Return the background color used for menu.

Returns:
Menu background color.

Definition at line 779 of file menu.c.

color_t MENU_GetTextColor ( void   ) 

Return the color used for text menu.

Returns:
Menu text color.

Definition at line 743 of file menu.c.

void MENU_Print ( const u8 *  str  ) 

Display a popup menu with a string.

Parameters:
[in] str The string to display.

Definition at line 1000 of file menu.c.

void MENU_Question ( const u8 *  str,
bool *  answer 
)

Dedicated menu for ask question and yes/no responses.

Parameters:
[in] str A pointer to the string containing the question.
[out] answer 1 for yes, 0 for no.

Definition at line 947 of file menu.c.

enum MENU_code MENU_Quit ( void   ) 

Leave the current menu (stand for "cancel") and clear screen.

Return values:
MENU_LEAVE 

Definition at line 707 of file menu.c.

void MENU_Remove ( void   ) 

Remove current menu, clear screen and set pointer "on".

Definition at line 795 of file menu.c.

void MENU_RestoreAppliDivider ( void   ) 

Restore the default divider (MENU) for the application divider

Definition at line 1040 of file menu.c.

void MENU_Set ( tMenu mptr  ) 

Display provided menu.

Parameters:
[in] mptr A pointer to the menu to display.

Definition at line 821 of file menu.c.

void MENU_SetAppliDivider ( divider_t  divider  ) 

Set new value of the call time application divider. Upon each systick, CircleOS will have the opportunity to call your application or not, depending on this divider. If divider = 1, your application will be called upon each systick interrupt. If divider == 2 your application will be called only every other systick occurrence.

Parameters:
[in] divider : The new value of the divider.

Definition at line 1024 of file menu.c.

void MENU_SetBGndColor ( color_t  BGndColor  ) 

Set the background color used for menu.

Parameters:
[in] BGndColor New menu background color.

Definition at line 761 of file menu.c.

void MENU_SetTextColor ( color_t  TxtColor  ) 

Set the color used for text menu.

Parameters:
[in] TxtColor New color used for menu text.

Definition at line 725 of file menu.c.