hello-world/settings/menu.h

Go to the documentation of this file.
00001 #ifndef __MENU_H__
00002 #define __MENU_H__
00003 
00004 /**
00005  * File Name  : menu.h
00006  *
00007  * Description: Control the popup menus
00008  */
00009 
00010 /*
00011  * This file is part of hello-world-settings.
00012  *
00013  * hello-world is free software: you can redistribute it and/or modify
00014  * it under the terms of the GNU General Public License as published by
00015  * the Free Software Foundation, either version 2 of the License, or
00016  * (at your option) any later version.
00017  *
00018  * hello-world is distributed in the hope that it will be useful,
00019  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00020  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
00021  * GNU General Public License for more details.
00022  *
00023  * You should have received a copy of the GNU General Public License
00024  * along with this program. If not, see <http://www.gnu.org/licenses/>.
00025  */
00026 
00027 /**
00028  * Copyright (C) 2009 iRex Technologies B.V.
00029  * All rights reserved.
00030  */
00031 
00032 
00033 //----------------------------------------------------------------------------
00034 // Include Files
00035 //----------------------------------------------------------------------------
00036 
00037 G_BEGIN_DECLS
00038 
00039 
00040 //----------------------------------------------------------------------------
00041 // Definitions
00042 //---------------------------------------------------------------------------- 
00043 
00044 // states of a menu item
00045 #define MENU_STATE_NORMAL       "normal";
00046 #define MENU_STATE_SELECTED     "selected";
00047 #define MENU_STATE_DISABLED     "disabled";
00048 
00049 
00050 //----------------------------------------------------------------------------
00051 // Forward Declarations
00052 //----------------------------------------------------------------------------
00053 
00054 
00055 //----------------------------------------------------------------------------
00056 // Type Declarations
00057 //----------------------------------------------------------------------------
00058 
00059 
00060 //----------------------------------------------------------------------------
00061 // Global Constants
00062 //----------------------------------------------------------------------------
00063 
00064 
00065 //============================================================================
00066 // Public Functions
00067 //============================================================================
00068 
00069 /**---------------------------------------------------------------------------
00070  *
00071  * Name :  menu_init
00072  *
00073  * @brief  Initialise popup menus
00074  *
00075  * @param  --
00076  *
00077  * @return --
00078  *
00079  *--------------------------------------------------------------------------*/
00080 void menu_init ( void );
00081 
00082 
00083 /**---------------------------------------------------------------------------
00084  *
00085  * Name :  menu_destroy
00086  *
00087  * @brief  Remove the popup menus
00088  *
00089  * @param  --
00090  *
00091  * @return --
00092  *
00093  *--------------------------------------------------------------------------*/
00094 void menu_destroy ( void );
00095 
00096 
00097 /**---------------------------------------------------------------------------
00098  *
00099  * Name :  menu_show
00100  *
00101  * @brief  Display the proper popup menu for the current context
00102  *
00103  * @param  --
00104  *
00105  * @return --
00106  *
00107  *--------------------------------------------------------------------------*/
00108 void menu_show ( void );
00109 
00110 
00111 /**---------------------------------------------------------------------------
00112  *
00113  * Name :  menu_set_text
00114  *
00115  * @brief  Initiliase text items in popup menu(s)
00116  *
00117  * @param  --
00118  *
00119  * @return --
00120  *
00121  *--------------------------------------------------------------------------*/
00122 void menu_set_text ( void );
00123 
00124 
00125 //----------------------------------------------------------------------------
00126 // Callbacks from popupmenu
00127 //----------------------------------------------------------------------------
00128 
00129 /**---------------------------------------------------------------------------
00130  *
00131  * Name :  menu_on_item_activated
00132  *
00133  * @brief  Handle a menu button that has been pressed by the user
00134  *
00135  * @param  [in] item  - item name of the activated item
00136  * @param  [in] group - name of the parent group of the activated item
00137  * @param  [in] menu  - name of the current menu
00138  * @param  [in] state - state of the item when activated
00139  *
00140  * @return --
00141  *
00142  *--------------------------------------------------------------------------*/
00143 void menu_on_item_activated ( const gchar *item,
00144                               const gchar *group,
00145                               const gchar *menu,
00146                               const gchar *state );
00147 
00148 
00149 G_END_DECLS
00150 
00151 #endif /* __MENU_H__ */
Generated by  doxygen 1.6.2-20100208