资源描述:
《添加菜单菜单(vogins)》由会员上传分享,免费在线阅读,更多相关内容在应用文档-天天文库。
1、一、 菜单的修改或增加:以一个例子的方式介绍如何添加一个菜单,例子如下: 在主菜单的“设置”菜单下增加一个“我的设定”子菜单,“我的设定”下有两个子菜单:“我的设定1”和“我的设定2”,打开这两个菜单,分别显示一幅动画。步骤如下: 1.在..plutommimmiSettingSettingInc目录下的SettingDefs.h文件中增加如下内容:a.enumSTR_SETTING_LIST的最后增加三个字符串ID的声明:STR_MY_SETTING,STR_MY_SETTING1,STR_MY_SETTING2, b.enumSCR_SETTING_LIS
2、T的最后增加三个ScreenID的声明: SCR_MY_SETTING, SCR_MY_SETTING1, SCR_MY_SETTING2, c.enumIMG_SETTING_LIST的最后增加一个ImageID的声明:IMG_MY_SETTING, d.在..plutommimmiInc目录下GlobalMenuItems.h文件中enum GLOBALMENUITEMSID 的最后增加三个菜单ID的声明:(有的是在本AP或模块的*Defs.h中声明)MENU_MY_SETTING,MENU_MY_SETTING1,MENU_MY_SET
3、TING2, 2.在..plutommiCustomerCustResourcePLUTO_MMI目录下的Ref_list.txt中添加三个字符串: STR_MY_SETTINGUndefined10MySettingMySetting我的设定我的设定STR_MY_SETTING1Undefined10MySetting1MySetting1我的设定1我的设定1STR_MY_SETTING2Undefined10MySetting2MySetting2我的设定2我的设定2 3.在..plutommiCustomerCustResourcePLUTO_
4、MMIRes_MMI目录下的Res_Setting.c增加如下资源:ADD_APPLICATION_MENUITEM((MENU_MY_SETTING,MAIN_MENU_SETTINGS_MENUID ,2,MENU_MY_SETTING1,MENU_MY_SETTING2,SHOW,MOVEABLEWITHINPARENT, DISP_LIST,STR_MY_SETTING,0)); ADD_APPLICATION_MENUITEM((MENU_MY_SETTING1,MENU_MY_SETTING,0,SHOW,MOVEABLEWITHINPARE
5、NT,DISP_LIST,STR_MY_SETTING1,0)); ADD_APPLICATION_MENUITEM((MENU_MY_SETTING2,MENU_MY_SETTING,0,SHOW,MOVEABLEWITHINPARENT,DISP_LIST,STR_MY_SETTING2,0)); ADD_APPLICATION_IMAGE2(IMG_MY_SETTING,CUST_IMG_PATH"\\MainLCD\\SubMenu\Settings\\MY_SETTING.GIF","MySetting."); A
6、DD_APPLICATION_STRING2(STR_MY_SETTING,"MySetting","MySetting"); ADD_APPLICATION_STRING2(STR_MY_SETTING1,"MySetting1","MySetting1"); ADD_APPLICATION_STRING2(STR_MY_SETTING2,"MySetting2","MySetting2"); 4.在..plutommiCustomerCustResourcePLUTO_MMIRes_MMI目录下的Res_MainMenu.c中修改如下:
7、ADD_APPLICATION_MENUITEM((MAIN_MENU_SETTINGS_MENUID,IDLE_SCREEN_MENU_ID,5,MENU9102_INITIAL_SETUP, . . . 改为: ADD_APPLICATION_MENUITEM((MAIN_MENU_SETTINGS_MENUID,IDLE_SCREEN_ MENU_ID,6,MENU_MY_SETTING,MENU91