void EntryCALLSETBarringIn(void) { //micha1229 // U16 nDispAttribute; /* Stores display attribue */ U8* guiBuffer; /* Buffer holding history data */ U16 nNumofItem; U16 nStrItemList[MAX_SUB_MENUS]; /*U32 maskingByte=0xFFFFFFFF; U32 menuItemId=0xFFFFFFFF;*/ EntryNewScreen(SCR_ID_CALLSET_BARRING_IN, NULL, EntryCALLSETBarringIn, NULL); /* Get current screen info into gui buffer for history purposes*/ guiBuffer = GetCurrGuiBuffer(SCR_ID_CALLSET_BARRING_IN); /* Retrieve no of child of menu item to be displayed */ nNumofItem = GetNumOfChild_Ext(MENU_CALL_BARRING_INCOMING); /* Get attribute of menu to be displayed */ // nDispAttribute = GetDispAttributeOfItem(MENU8237_SCR8093_MNGCALL_MENU_BARRING); /* Retrieve string ids in sequence of given menu item to be displayed */ GetSequenceStringIds_Ext(MENU_CALL_BARRING_INCOMING, nStrItemList); /* Set current parent id*/ SetParentHandler(MENU_CALL_BARRING_INCOMING); /* Register highlight handler to be called in menu screen */ RegisterHighlightHandler(ExecuteCurrHiliteHandler); #if 0 /* under construction !*/ /* under construction !*/ /* under construction !*/ /* under construction !*/ /* under construction !*/ /* under construction !*/ /* under construction !*/ #endif /* 0 */ /* Display Category Screen */ ShowCategory15Screen(STR_MENU_BARRING_INCOMING_MAIN, MAIN_MENU_TITLE_SETTINGS_ICON, STR_GLOBAL_OK , IMG_GLOBAL_OK, STR_GLOBAL_BACK, IMG_GLOBAL_BACK,nNumofItem, nStrItemList, (U16 *)gIndexIconsImageList,1,0,guiBuffer); /* Register function with right softkey */ SetRightSoftkeyFunction(GoBackHistory,KEY_EVENT_UP); /* Register Exit handler */ return; }
/***************************************************************************** * FUNCTION * mmi_java_entry_terminate_dialog * DESCRIPTION * The entry function to ask user if they want to terminate/Pause Java * PARAMETERS * void * RETURNS * void *****************************************************************************/ void mmi_java_entry_terminate_dialog(void) /* called by JAVA adaptor, also in mmi task */ { /*----------------------------------------------------------------*/ /* Local Variables */ /*----------------------------------------------------------------*/ U8 *guiBuffer; U8 *icon_items[2]; U8 *text_items[2]; /*----------------------------------------------------------------*/ /* Code Body */ /*----------------------------------------------------------------*/ EntryNewScreen( SCR_JAVA_TERMINATE_DIALOG, mmi_java_entry_terminate_dialog_exit, mmi_java_entry_terminate_dialog, NULL); guiBuffer = GetCurrGuiBuffer(SCR_JAVA_TERMINATE_DIALOG); RegisterHighlightHandler(mmi_java_highlight_handler); memset(icon_items, 0, sizeof(icon_items)); text_items[0] = (PU8) GetString(STR_JAVA_PAUSE); text_items[1] = (PU8) GetString(STR_JAVA_TERMINATE); ShowCategory32Screen( format_asking_string(STR_JAVA_TERMINATE_DIALOG_TITLE), NULL, (PU8) GetString(STR_GLOBAL_OK), (PU8) GetImage(IMG_GLOBAL_OK), (PU8) GetString(STR_GLOBAL_BACK), (PU8) GetImage(IMG_GLOBAL_BACK), 2, text_items, icon_items, 0, 0, guiBuffer); SetLeftSoftkeyFunction(mmi_java_terminate_dialog_yes_hdlr, KEY_EVENT_UP); SetRightSoftkeyFunction(mmi_java_terminate_dialog_no_hdlr, KEY_EVENT_UP); }
/***************************************************************************** * FUNCTION * mmi_brw_address_list_entry_options * DESCRIPTION * Entry function for Enter Address Options screen. * PARAMETERS * void * RETURNS * void *****************************************************************************/ void mmi_brw_address_list_entry_options(void) { /*----------------------------------------------------------------*/ /* Local Variables */ /*----------------------------------------------------------------*/ U16* UC_list_of_items; U8 *guiBuffer; S32 num_of_items; /*----------------------------------------------------------------*/ /* Code Body */ /*----------------------------------------------------------------*/ EntryNewScreen(SCR_ID_BRW_ENTER_ADDRESS_OPTIONS, NULL, mmi_brw_address_list_entry_options, NULL); guiBuffer = GetCurrGuiBuffer(SCR_ID_BRW_ENTER_ADDRESS_OPTIONS); /*it saves the current screen as the browser top most screen*/ mmi_brw_set_top_screen_id(); num_of_items = GetNumOfChild(MENU_ID_BRW_ENTER_ADR_OPTIONS); UC_list_of_items = OslMalloc(sizeof(U16)*num_of_items); GetSequenceStringIds(MENU_ID_BRW_ENTER_ADR_OPTIONS, UC_list_of_items); SetParentHandler(MENU_ID_BRW_ENTER_ADR_OPTIONS); RegisterHighlightHandler(ExecuteCurrHiliteHandler); ShowCategory15Screen( STR_GLOBAL_OPTIONS, GetRootTitleIcon(SERVICES_WAP_MENU_ID), STR_GLOBAL_OPTIONS, 0, STR_GLOBAL_BACK, 0, num_of_items, UC_list_of_items, (U16*) gIndexIconsImageList, LIST_MENU, 0, guiBuffer); ChangeLeftSoftkey(STR_GLOBAL_OK, IMG_GLOBAL_OK); SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP); SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN); OslMfree(UC_list_of_items); }
/***************************************************************************** * FUNCTION * mmi_brw_entry_address_list * DESCRIPTION * Entry function for enter address menu * PARAMETERS * void * RETURNS * void *****************************************************************************/ void mmi_brw_entry_address_list(void) { /*----------------------------------------------------------------*/ /* Local Variables */ /*----------------------------------------------------------------*/ U8 *guiBuffer = NULL; U8 highlight_index = 0; /*----------------------------------------------------------------*/ /* Code Body */ /*----------------------------------------------------------------*/ EntryNewScreen(SCR_ID_BRW_ENTER_ADDRESS, NULL, mmi_brw_entry_address_list, NULL); guiBuffer = GetCurrGuiBuffer(SCR_ID_BRW_ENTER_ADDRESS); /*it saves the current screen as the browser top most screen*/ mmi_brw_set_top_screen_id(); if (mmi_brw_address_list_get_hiliter_flag() && guiBuffer != NULL && guiBuffer[2] != 0) { guiBuffer = NULL; mmi_brw_address_list_set_hiliter_flag(MMI_FALSE); highlight_index = 1; } RegisterHighlightHandler(mmi_brw_address_list_scr_highlight_hdlr); ShowCategory184Screen( STR_ID_BRW_ENTER_ADDRESS, GetRootTitleIcon(SERVICES_WAP_MENU_ID), STR_GLOBAL_OK, 0, STR_GLOBAL_BACK, 0, g_brw_cntx.total_address_list_items + 1, mmi_brw_address_list_get_item, 0, highlight_index, guiBuffer); SetRightSoftkeyFunction(mmi_brw_address_list_GoBackHistory, KEY_EVENT_UP); SetKeyHandler(mmi_brw_address_list_GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN); }
/***************************************************************************** * FUNCTION * mmi_bt_avrcp_ct_main * DESCRIPTION * This function is to * PARAMETERS * void * RETURNS * void *****************************************************************************/ void mmi_bt_avrcp_ct_main(void) { /*----------------------------------------------------------------*/ /* Local Variables */ /*----------------------------------------------------------------*/ U8 *gui_buffer; /*----------------------------------------------------------------*/ /* Code Body */ /*----------------------------------------------------------------*/ EntryNewScreen(SCR_ID_BT_AVCRP_CT_MAIN, NULL, mmi_bt_avrcp_ct_main, NULL); gui_buffer = GetCurrGuiBuffer(SCR_ID_BT_AVCRP_CT_MAIN); if (gui_buffer == NULL) { g_mmi_bt_avrcp_ct_curr_cmd = 0; srv_avrcp_set_cmd_frame_cnf_hdlr((AVRCP_SRV_CMD_CNF_CALLBACK)mmi_bt_avrcp_ct_cmd_confirm); } RegisterHighlightHandler(mmi_bt_avrcp_ct_main_list_highlight_hdlr); ShowCategory184Screen( STR_GLOBAL_OK, /* Title ID*/ IMG_GLOBAL_OK, /* Title ICON */ STR_GLOBAL_SELECT, IMG_GLOBAL_OK, STR_GLOBAL_BACK, IMG_GLOBAL_BACK, MMI_BT_AVRCP_CMD_NUM, mmi_bt_avrcp_ct_main_list_item, NULL, g_mmi_bt_avrcp_ct_curr_cmd, gui_buffer); /* register LSK, RSK hanlders */ SetLeftSoftkeyFunction(mmi_bt_avrcp_ct_send_cmd, KEY_EVENT_UP); SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP); /* register left right arrow key handler */ SetKeyHandler(mmi_bt_avrcp_ct_send_cmd, KEY_RIGHT_ARROW, KEY_EVENT_DOWN); SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN); }
/***************************************************************************** * FUNCTION * mmi_java_entry_get_permission * DESCRIPTION * The entry function to get user's permission to use Network or some * resource. * PARAMETERS * void * RETURNS * void *****************************************************************************/ void mmi_java_entry_get_permission(void) { /*----------------------------------------------------------------*/ /* Local Variables */ /*----------------------------------------------------------------*/ U8 *guiBuffer; U16 strid = mmi_java_permission_strid(mmi_java_get_permission_msg.title_id); S8 *buffer; /*----------------------------------------------------------------*/ /* Code Body */ /*----------------------------------------------------------------*/ EntryNewScreen(SCR_JAVA_GET_PERMISSION, NULL, mmi_java_entry_get_permission, NULL); guiBuffer = GetCurrGuiBuffer(SCR_JAVA_GET_PERMISSION); mmi_java_get_permission_index = mmi_java_get_permission_msg.chosen_id; buffer = (S8*)subMenuData; kal_mem_set(buffer, 0, MAX_SUB_MENUS * MAX_SUB_MENU_SIZE); mmi_ucs2cpy((S8*)buffer, (S8*)GetString(strid)); if(mmi_java_get_permission_msg.appendix) { mmi_ucs2cat((S8*)buffer, (S8*)mmi_java_get_permission_msg.appendix); } ShowCategory74Screen( STR_JAVA_PERMISSION_TITLE, mmi_java_get_title_icon(), STR_GLOBAL_YES, IMG_GLOBAL_YES, STR_GLOBAL_NO, IMG_GLOBAL_NO, (PU8) buffer, mmi_ucs2strlen((PS8) buffer), NULL); SetLeftSoftkeyFunction(mmi_java_get_permission_lsk_hdlr, KEY_EVENT_UP); SetRightSoftkeyFunction(mmi_java_get_permission_rsk_hdlr, KEY_EVENT_UP); }
void EntryShowRegisterProgress(void) { MTPNP_UINT8 *guiBuffer; EntryNewScreen(SCR_REGISTERPROG, MTPNP_NULL, EntryShowRegisterProgress, MTPNP_NULL); guiBuffer = GetCurrGuiBuffer(SCR_REGISTERPROG); SetParentHandler(MENU_MTPNP_HELPINFO); RegisterHighlightHandler(ExecuteCurrHiliteHandler); MTPNP_OSAL_memset(UnicodeDisplayBuf, 0, sizeof(UnicodeDisplayBuf)); MTPNP_PFAL_Unicode_String_Copy((MTPNP_CHAR *) UnicodeDisplayBuf, (const MTPNP_CHAR *) GetString(STRING_MTPNP_REGISTER_TIP)); ShowCategory74Screen(STRING_MTPNP_REGISTER, 0, (MTPNP_UINT16) NULL, 0, STR_GLOBAL_BACK, 0, (MTPNP_UINT8 *) UnicodeDisplayBuf, sizeof(UnicodeDisplayBuf), guiBuffer); SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP); }
/************************************************************** FUNCTION NAME : EntryScrPreferedInputMethodList PURPOSE : Entry function for input method screen INPUT PARAMETERS : nil OUTPUT PARAMETERS : nil RETURNS : void **************************************************************/ void EntryScrPreferedInputMethodList(void) { U8* pGuiBuffer; U8 i; InitPreferedInputMethod(); i = 0; while(MMI_all_prefered_input_mode_set[i] != MMI_prefered_input_type) { if(MMI_all_prefered_input_mode_set[i] == 0xffff) { i=0; break; } else i++; } currInputMethodIndex = i; /* Call Exit Handler*/ //ExecuteCurrExitHandler(); EntryNewScreen(SCR_INPUT_METHOD_SELECTION, ExitInputMethodSelectScreen, NULL, NULL); /* Get current screen info into gui buffer for history purposes*/ pGuiBuffer = GetCurrGuiBuffer(SCR_INPUT_METHOD_SELECTION); /* Register highlight handler to be called in menu screen */ RegisterHighlightHandler(HighlightCurrentInputMethod); /* Display Screen */ ShowCategory36Screen( STR_MENU_INPUT_METHOD, MAIN_MENU_TITLE_SETTINGS_ICON, STR_GLOBAL_OK, IMG_GLOBAL_OK, STR_GLOBAL_BACK, IMG_GLOBAL_BACK, gnInputMethods, (U8**)inputMethodList, currInputMethodIndex,pGuiBuffer); /* Register function with left/right softkey */ SetRightSoftkeyFunction(GoBackHistory,KEY_EVENT_UP); SetLeftSoftkeyFunction(SelectInputMethodHandler, KEY_EVENT_UP); /* Register function with left/right arrow key */ SetKeyHandler(0, KEY_RIGHT_ARROW, KEY_EVENT_DOWN); SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN); /* Register Exit handler */ //SetExitHandler(SCR_INPUT_METHOD_SELECTION, ExitInputMethodSelectScreen); return; }
void jMms_template_entry_handler () { U8* guiBuffer; EntryNewScreen (SCR_ID_MMS_TEMPLATE, NULL, jMms_template_entry_handler, NULL) ; guiBuffer = GetCurrGuiBuffer (SCR_ID_MMS_TEMPLATE) ; //RegisterHighlightHandler (ExecuteCurrHiliteHandler) ; ShowCategory184Screen(STR_ID_MMS_TEXT, IMG_SMS_ENTRY_SCRN_CAPTION, STR_GLOBAL_OK, IMG_GLOBAL_OK, STR_GLOBAL_BACK, IMG_GLOBAL_BACK, 10, get_templates_item_data, 0, 0, guiBuffer); SetLeftSoftkeyFunction (Select_hltd_template, KEY_EVENT_UP); SetRightSoftkeyFunction (GoBackHistory, KEY_EVENT_UP); //jmms_MmsEntryRegisterEndKeyHandler(); //calling the same end key handle as adresssubmenu //SetKeyHandler(jmms_ComposeEndKeyHandler, KEY_END, KEY_EVENT_DOWN) ; }
/************************************************************** FUNCTION NAME : EntrySECSETFDNOption(void) PURPOSE : Entry screen of FDL list Options, when list is not empty. INPUT PARAMETERS : nil OUTPUT PARAMETERS : nil RETURNS : void Author : Vanita Jain **************************************************************/ void EntrySECSETFDNOption() { U16 nStrItemList[MAX_SUB_MENUS];/* Stores the strings id of submenus returned */ U16 nNumofItem; /* Stores no of children in the submenu*/ //micha1229 // U16 nDispAttribute; /* Stores display attribue */ U8* guiBuffer; /* Buffer holding history data */ EntryNewScreen(SCR_ID_SECSET_FDN_OPTION, NULL, EntrySECSETFDNOption, NULL); /* 2 Get current screen to gui buffer for history purposes*/ guiBuffer = GetCurrGuiBuffer(SCR_ID_SECSET_FDN_OPTION); /* 3. Retrieve no of child of menu item to be displayed */ nNumofItem = GetNumOfChild(MENU8234_FDL_VIEW_OPTIONS_MAIN ); /* 4. Get attribute of menu to be displayed */ // nDispAttribute = GetDispAttributeOfItem(MENU8234_FDL_VIEW_OPTIONS_MAIN ); /* 5. Retrieve string ids in sequence of given menu item to be displayed */ GetSequenceStringIds(MENU8234_FDL_VIEW_OPTIONS_MAIN , nStrItemList); /* 6 Set current parent id*/ SetParentHandler(MENU8234_FDL_VIEW_OPTIONS_MAIN ); /* 7 Register highlight handler to be called in menu screen */ RegisterHighlightHandler(ExecuteCurrHiliteHandler); /* 8 Display Category15 Screen */ ShowCategory15Screen(STR_GLOBAL_OPTIONS, MAIN_MENU_TITLE_SETTINGS_ICON, STR_GLOBAL_OK, IMG_GLOBAL_OK, STR_GLOBAL_BACK, IMG_GLOBAL_BACK, nNumofItem, nStrItemList, (PU16)gIndexIconsImageList, LIST_MENU, 0, guiBuffer); /* 9.Register function with right softkey */ SetRightSoftkeyFunction(GoBackHistory,KEY_EVENT_UP); }
/***************************************************************************** * FUNCTION * mmi_rmgr_http_profile_entry_main * DESCRIPTION * Entry function of http profile main screen * PARAMETERS * void * RETURNS * void *****************************************************************************/ void mmi_rmgr_http_profile_entry_main(void) { /*----------------------------------------------------------------*/ /* Local Variables */ /*----------------------------------------------------------------*/ U8 *guiBuffer; U32 i; /*----------------------------------------------------------------*/ /* Code Body */ /*----------------------------------------------------------------*/ EntryNewScreen(SCR_ID_RMGR_HTTP_PROFILE_MAIN, NULL, mmi_rmgr_http_profile_entry_main, NULL); for (i = 0; i < MMI_RMGR_MAX_HTTP_PROFILE_NUM; i++) { subMenuDataPtrs[i] = (U8*) L"<http>"; } guiBuffer = GetCurrGuiBuffer(SCR_ID_RMGR_HTTP_PROFILE_MAIN); RegisterHighlightHandler(mmi_rmgr_http_profile_highlight_hdlr); /* set high item as current http profile setting */ mmi_rmgr_p->http_profile_hilite_idx = mmi_rmgr_p->http_profile_idx; ShowCategory36Screen( STR_ID_RMGR, IMG_ID_RMGR_ICON, STR_GLOBAL_OK, IMG_GLOBAL_OK, STR_GLOBAL_BACK, IMG_GLOBAL_BACK, MMI_RMGR_MAX_HTTP_PROFILE_NUM, subMenuDataPtrs, mmi_rmgr_p->http_profile_hilite_idx, guiBuffer); SetLeftSoftkeyFunction(mmi_rmgr_http_profile_entry_done, KEY_EVENT_UP); SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP); }
/***************************************************************************** * FUNCTION * mmi_brw_entry_service_inbox_options * DESCRIPTION * Entry function for service inbox options screen. * PARAMETERS * void * RETURNS * void *****************************************************************************/ void mmi_brw_entry_service_inbox_options(void) { /*----------------------------------------------------------------*/ /* Local Variables */ /*----------------------------------------------------------------*/ U16 UC_list_of_items[3]; U8 *guiBuffer; S32 num_of_items; /*----------------------------------------------------------------*/ /* Code Body */ /*----------------------------------------------------------------*/ EntryNewScreen(SCR_ID_BRW_SERVICE_INBOX_OPTIONS, NULL, mmi_brw_entry_service_inbox_options, NULL); guiBuffer = GetCurrGuiBuffer(SCR_ID_BRW_SERVICE_INBOX_OPTIONS); num_of_items = GetNumOfChild(MENU_ID_BRW_PUSH_MSG_OPTIONS); GetSequenceStringIds(MENU_ID_BRW_PUSH_MSG_OPTIONS, UC_list_of_items); SetParentHandler(MENU_ID_BRW_PUSH_MSG_OPTIONS); RegisterHighlightHandler(ExecuteCurrHiliteHandler); ShowCategory15Screen( STR_ID_BRW_OPTION, GetRootTitleIcon(SERVICES_WAP_MENU_ID), STR_GLOBAL_OK, 0, STR_GLOBAL_BACK, 0, num_of_items, UC_list_of_items, (U16*) gIndexIconsImageList, LIST_MENU, 0, guiBuffer); SetRightSoftkeyFunction(mmi_brw_entry_service_inbox_options_back, KEY_EVENT_UP); SetKeyHandler(mmi_brw_entry_service_inbox_options_back, KEY_LEFT_ARROW, KEY_EVENT_DOWN); }
static void mmiapi_enter_resume_fullscreen_editor(void) { U8* guiBuffer = NULL; EntryNewScreen (MMIAPI_SCREEN_FULLSCREEN_EDITOR, 0, mmiapi_enter_resume_fullscreen_editor, NULL); guiBuffer = GetCurrGuiBuffer (MMIAPI_SCREEN_FULLSCREEN_EDITOR); ShowCategory5Screen (0, 0, STR_GLOBAL_OPTIONS, 0, STR_GLOBAL_BACK, 0, mmiapi_fullscreen_editor_input_type, (U8*) mmiapi_fullscreen_editor_input_buffer, mmiapi_fullscreen_editor_input_buffer_max_len, guiBuffer); #ifdef __MMI_GB__ GBSetInputboxLSKFunction (mmiapi_goto_fullscreen_editor_option); #endif SetLeftSoftkeyFunction (mmiapi_goto_fullscreen_editor_option, KEY_EVENT_UP); SetCategory5RightSoftkeyFunction (CancelGotoJavaSreen, KEY_EVENT_UP); RegisterInputMethodScreenCloseFunction (GoBackHistory ); }
/************************************************************** FUNCTION NAME : EntrySECSETFDNList(void) PURPOSE : Entry screen to view FDl list INPUT PARAMETERS : nil OUTPUT PARAMETERS : nil RETURNS : void Author : Vanita Jain **************************************************************/ void EntrySECSETFDNList() { U8 *pstfdlist[MAX_SIM_ENTRIES],*fdlHint[MAX_SIM_ENTRIES]; U16 index; U8* guiBuffer; U16 fdlimagelist[MAX_SIM_ENTRIES]; EntryNewScreen(SCR_ID_SECSET_FDN_LIST, NULL, EntrySECSETFDNList, NULL); guiBuffer = GetCurrGuiBuffer(SCR_ID_SECSET_FDN_LIST); /* Getting the Index from history */ for(index = 0; index < gpFDLBDLContext->FDNBDNCount; index++) { if(gpFDLBDLContext->FDLBDLEntries[index].alpha_id.name[0] != '\0') { pstfdlist[index] = (U8*)gpFDLBDLContext->FDLBDLEntries[index].alpha_id.name; fdlHint[index] = (U8*)gpFDLBDLContext->FDLBDLEntries[index].tel.number; } else { pstfdlist[index] = (U8*)gpFDLBDLContext->FDLBDLEntries[index].tel.number; fdlHint[index] = NULL; } fdlimagelist[index]= IMG_STORAGE_SIM; } RegisterHighlightHandler(GetActiveIndex); if( guiBuffer != NULL) { memset( (void *) guiBuffer, 0, 2); } if (( gpFDLBDLContext->HighlightedFDN >= gpFDLBDLContext->FDNBDNCount) && (gpFDLBDLContext->FDNBDNCount > 0)) gpFDLBDLContext->HighlightedFDN = gpFDLBDLContext->FDNBDNCount-1; if(gpFDLBDLContext->FDNBDNCount == 0) { pstfdlist[0] = (U8*)GetString(STR_GLOBAL_EMPTY_LIST); fdlimagelist[0]= 0; fdlHint[0] = NULL; ShowCategory6Screen(STR_SCR8054_CALL_FDL_CAPTION, MAIN_MENU_TITLE_SETTINGS_ICON, STR_GLOBAL_ADD, IMG_GLOBAL_OPTIONS, STR_GLOBAL_BACK, IMG_GLOBAL_BACK, 1, pstfdlist, NULL,0, guiBuffer); gpFDLBDLContext->FDNBDNEdit = FALSE ; memset(gpFDLBDLContext->FDLBDLName,0,(MAX_NAME_LEN_FSB_LIST+1)*ENCODING_LENGTH); memset(gpFDLBDLContext->FDLBDLNumber,0,(MAX_NUMBER_LEN_FSB_LIST+1+1)*ENCODING_LENGTH); SetLeftSoftkeyFunction(EntrySECSETFDNDetails,KEY_EVENT_UP); //micha0529 SetKeyHandler(EntrySECSETFDNDetails, KEY_RIGHT_ARROW, KEY_EVENT_DOWN); SetRightSoftkeyFunction(GoBackHistory,KEY_EVENT_UP); SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN); SetKeyHandler(0,KEY_SEND,KEY_EVENT_UP); } else { ShowCategory53Screen(STR_SCR8054_CALL_FDL_CAPTION, MAIN_MENU_TITLE_SETTINGS_ICON, //micha0610 STR_GLOBAL_OPTIONS, IMG_GLOBAL_OPTIONS, STR_GLOBAL_BACK, IMG_GLOBAL_BACK, gpFDLBDLContext->FDNBDNCount, pstfdlist,fdlimagelist, fdlHint,0, gpFDLBDLContext->HighlightedFDN, guiBuffer); SetLeftSoftkeyFunction(EntrySECSETFDNOption,KEY_EVENT_UP); //micha0529 SetKeyHandler(EntrySECSETFDNOption, KEY_RIGHT_ARROW, KEY_EVENT_DOWN); SetRightSoftkeyFunction(GoBackHistory,KEY_EVENT_UP); SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN); #ifdef __MMI_MULTI_SIM__ MTPNP_PFAL_CC_HandleSendKeys(FdlMakeCall, KEY_EVENT_DOWN); #if defined(TGT_GALLITE_G800)||defined(TGT_TD_4SIM) ClearKeyHandler( KEY_ENTER, KEY_EVENT_DOWN); SetKeyHandler(EntrySECSETFDNOption,KEY_ENTER,KEY_EVENT_UP ); #endif #else SetKeyHandler(FdlMakeCall, KEY_SEND, KEY_EVENT_DOWN); #endif } }
/***************************************************************************** * FUNCTION * mmi_netset_entry_user_ctrl_plmn_add_data * DESCRIPTION * * PARAMETERS * void * RETURNS * void *****************************************************************************/ void mmi_netset_entry_user_ctrl_plmn_add_data(void) { /*----------------------------------------------------------------*/ /* Local Variables */ /*----------------------------------------------------------------*/ U8 *guiBuffer; /* Buffer holding history data */ U8 *inputBuffer; /* added for inline edit history */ U16 inputBufferSize; /* added for inline edit history */ U16 IconList[] = {IMG_GLOBAL_L1, 0, IMG_GLOBAL_L2, 0}; /*----------------------------------------------------------------*/ /* Code Body */ /*----------------------------------------------------------------*/ EntryNewScreen(SCR_ID_NETSET_USER_CTRL_PLMN_ADD, mmi_netset_exit_user_ctrl_plmn_add_data, NULL, NULL); guiBuffer = GetCurrGuiBuffer(SCR_ID_NETSET_USER_CTRL_PLMN_ADD); inputBuffer = GetCurrNInputBuffer(SCR_ID_NETSET_USER_CTRL_PLMN_ADD, &inputBufferSize); /* added for inline edit history */ InitializeCategory57Screen(); mmi_netset_set_user_ctrl_plmn_add_inline_editor(); if (inputBuffer != NULL) { SetCategory57Data(wgui_inline_items, 4, inputBuffer); } ClearHighlightHandler(); if (IsScreenPresent(SCR_ID_NETSET_USER_CTRL_PLMN_LIST)) { ShowCategory57Screen( STR_GLOBAL_ADD, MAIN_MENU_TITLE_SETTINGS_ICON, STR_GLOBAL_OK, IMG_GLOBAL_OK, STR_GLOBAL_BACK, IMG_GLOBAL_BACK, 4, IconList, wgui_inline_items, 1, guiBuffer); } else { ShowCategory57Screen( STR_GLOBAL_ADD, MAIN_MENU_TITLE_SETTINGS_ICON, STR_GLOBAL_OK, IMG_GLOBAL_OK, STR_GLOBAL_BACK, IMG_GLOBAL_BACK, 4, IconList, wgui_inline_items, 3, guiBuffer); } SetCategory57RightSoftkeyFunctions(mmi_netset_save_user_ctrl_plmn_confirm, GoBackHistory); DeleteScreenIfPresent(SCR_ID_NETSET_UNKNOWN_PLMN_MSG); }
/***************************************************************************** * FUNCTION * mmi_netset_show_user_ctrl_plmn_list * DESCRIPTION * * PARAMETERS * void * RETURNS * void *****************************************************************************/ void mmi_netset_show_user_ctrl_plmn_list(void) { /*----------------------------------------------------------------*/ /* Local Variables */ /*----------------------------------------------------------------*/ PU8 guiBuffer; U8 *PlmnListHint[MAX_SUB_MENUS]; PU8 nStrItemList[MAX_USER_CTRL_PLMN]; U8 i; /*----------------------------------------------------------------*/ /* Code Body */ /*----------------------------------------------------------------*/ EntryNewScreen(SCR_ID_NETSET_USER_CTRL_PLMN_LIST, NULL, mmi_netset_show_user_ctrl_plmn_list, NULL); guiBuffer = GetCurrGuiBuffer(SCR_ID_NETSET_USER_CTRL_PLMN_LIST); RegisterHighlightHandler(mmi_netset_highlight_user_ctrl_plmn_list_hdlr); if (!gUserCtrlPlmnList.PlmnListSize) { /* no record */ nStrItemList[0] = (U8*) GetString(STR_GLOBAL_EMPTY_LIST); ShowCategory6Screen( STR_ID_NETSET_USER_CTRL_PLMN, MAIN_MENU_TITLE_SETTINGS_ICON, STR_GLOBAL_OPTIONS, IMG_GLOBAL_OPTIONS, STR_GLOBAL_BACK, IMG_GLOBAL_BACK, 1, (U8 **) nStrItemList, NULL, 0, guiBuffer); } else { for (i = 0; i < MAX_USER_CTRL_PLMN; i++) { nStrItemList[i] = NULL; } for (i = 0; i < gUserCtrlPlmnList.PlmnListSize; i++) { mmi_asc_to_ucs2( (S8*) gUserCtrlPlmnList.tmpPlmnListData[i], (S8*) gUserCtrlPlmnList.PrefPLMN[i] + sizeof(U32)); nStrItemList[i] = gUserCtrlPlmnList.tmpPlmnListData[i]; } mmi_netset_construct_user_ctrl_plmn_hint(PlmnListHint); ShowCategory6Screen( STR_ID_NETSET_USER_CTRL_PLMN, MAIN_MENU_TITLE_SETTINGS_ICON, STR_GLOBAL_OPTIONS, IMG_GLOBAL_OPTIONS, STR_GLOBAL_BACK, IMG_GLOBAL_BACK, gUserCtrlPlmnList.PlmnListSize, (U8 **) nStrItemList, PlmnListHint, 0, guiBuffer); } SetLeftSoftkeyFunction(mmi_netset_entry_user_ctrl_plmn_options, KEY_EVENT_UP); SetKeyHandler(mmi_netset_entry_user_ctrl_plmn_options, KEY_RIGHT_ARROW, KEY_EVENT_DOWN); SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP); SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN); }
/***************************************************************************** * FUNCTION * EntryCHISTResetCallLog * DESCRIPTION * Entry function of reset calls. * NA * * PARAMETERS * void * RETURNS * void *****************************************************************************/ void EntryCHISTResetCallLog(void) { /*----------------------------------------------------------------*/ /* Local Variables */ /*----------------------------------------------------------------*/ // U16 nDispAttribute; /* Stores display attribue */ U8 *guiBuffer; /* Buffer holding history data */ U16 nStrItemList[MAX_SUB_MENUS]; /* Stores the strings id of submenus returned */ U16 nNumofItem; /* Stores no of children in the submenu */ U16 ItemIcons[MAX_SUB_MENUS]; U8 *PopUpList[MAX_SUB_MENUS]; /*----------------------------------------------------------------*/ /* Code Body */ /*----------------------------------------------------------------*/ /* Call Exit Handler */ #ifdef __MMI_CH_NUMERIC_LIST_ICON__ EntryNewScreen(SCR_CALLHISTORY_RESETCALL, wgui_restore_list_menu_slim_style, EntryCHISTResetCallLog, NULL); #else /* __MMI_CH_NUMERIC_LIST_ICON__ */ EntryNewScreen(SCR_CALLHISTORY_RESETCALL, NULL, EntryCHISTResetCallLog, NULL); #endif /* __MMI_CH_NUMERIC_LIST_ICON__ */ /* Get current screen to gui buffer for history purposes */ guiBuffer = GetCurrGuiBuffer(SCR_CALLHISTORY_RESETCALL); /* Retrieve no of child of menu item to be displayed */ nNumofItem = GetNumOfChild(MENU8113_CALLHISTORY_RESETCALL); /* Get attribute of menu to be displayed */ /* nDispAttribute = GetDispAttributeOfItem( MENU8113_CALLHISTORY_RESETCALL ); */ /* Retrieve string ids in sequence of given menu item to be displayed */ GetSequenceStringIds(MENU8113_CALLHISTORY_RESETCALL, nStrItemList); GetSequenceImageIds(MENU8113_CALLHISTORY_RESETCALL, ItemIcons); /* Set current parent id */ SetParentHandler(MENU8113_CALLHISTORY_RESETCALL); /* Register highlight handler to be called in menu screen */ RegisterHighlightHandler(ExecuteCurrHiliteHandler); /* Construct the hint handler for the menu items */ ConstructHintsList(MENU8113_CALLHISTORY_RESETCALL, PopUpList); #ifdef __MMI_CH_NUMERIC_LIST_ICON__ wgui_override_list_menu_slim_style(WGUI_LIST_MENU_SLIM_STYLE_NUMBER); #endif /* Display the screen for the reset call logs */ ShowCategory52Screen( STR_MENU8113_CALLHISTORY_RESETCALL, IMG_SCR8056_CAPTION, STR_GLOBAL_OK, IMG_GLOBAL_OK, STR_GLOBAL_BACK, IMG_GLOBAL_BACK, nNumofItem, nStrItemList, ItemIcons, (U8 **)PopUpList, 0, 0, guiBuffer); /* Register function with right softkey */ SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN); SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP); return; }
/***************************************************************************** * FUNCTION * mmi_sample_3dgame_entry_app_screen * DESCRIPTION * enter dev3dgame screen - init an MMI environment for 3D game * PARAMETERS * void * RETURNS * void *****************************************************************************/ void mmi_sample_3dgame_entry_app_screen(void) { /*----------------------------------------------------------------*/ /* Local Variables */ /*----------------------------------------------------------------*/ PU8 gui_buffer; /*----------------------------------------------------------------*/ /* Code Body */ /*----------------------------------------------------------------*/ EntryNewScreen(SCR_ID_3D_GAME, mmi_sample_3dgame_exit_app_screen, mmi_sample_3dgame_entry_app_screen, NULL); gui_buffer = GetCurrGuiBuffer(SCR_ID_3D_GAME); /* reset clip */ gdi_layer_reset_clip(); gdi_layer_reset_text_clip(); /* enable multilayer */ gdi_layer_multi_layer_enable(); /* entry full screen app - will force status bar update */ entry_full_screen(); /* force all playing keypad tone off */ mmi_frm_kbd_set_tone_state(MMI_KEY_TONE_DISABLED); /* set audio volumn */ mdi_audio_set_volume(MDI_VOLUME_MEDIA, 4); /* vol level : 0 - 6 */ /* suspend background play */ mdi_audio_suspend_background_play(); /* stop MMI sleep */ TurnOnBacklight(0); /* clear keys */ ClearInputEventHandler(MMI_DEVICE_ALL); clear_category_screen_key_handlers(); /* set RSK-up to exit */ SetKeyHandler(GoBackHistory, KEY_RSK, KEY_EVENT_UP); /* clear background as black */ gdi_layer_clear(GDI_COLOR_BLACK); gdi_layer_blt_previous(0, 0, UI_device_width - 1, UI_device_height - 1); #ifndef WIN32 /* enable faster key handling */ mmi_frm_set_key_handle_in_high_frequency(MMI_TRUE); #endif /* WIN32 */ #ifdef __MMI_SUBLCD__ /* draw game icon on sublcd */ ForceSubLCDScreen(mmi_sample_3dgame_entry_sublcd); #endif /* __MMI_SUBLCD__ */ /* disalbe align timer, this will let timer more accurate */ UI_disable_alignment_timers(); /* start game */ if (gui_buffer == NULL) { /* TODO: start new game here .. */ } else { /* back from interrupt */ /* TODO: resume a existing game here .. */ } }
/***************************************************************************** * FUNCTION * mmi_brw_entry_service_inbox * DESCRIPTION * Entry function for service inbox * PARAMETERS * void * RETURNS * void *****************************************************************************/ void mmi_brw_entry_service_inbox(void) { /*----------------------------------------------------------------*/ /* Local Variables */ /*----------------------------------------------------------------*/ U8 *guiBuffer; U32 ret_code = 0; JC_UINT32 brw_total_msg_count = 0; JC_UINT32 brw_unread_msg_count = 0; /*----------------------------------------------------------------*/ /* Code Body */ /*----------------------------------------------------------------*/ if (NULL == g_mmi_brw_push_cntx.service_msg_list_p) { DisplayPopup( (PU8) GetString(STR_ID_BRW_PUSH_MEMORY_NOT_ENOUGH), IMG_GLOBAL_ERROR, 1, UI_POPUP_NOTIFYDURATION_TIME, ERROR_TONE); return; } ret_code = mmi_brw_get_push_statistics(&brw_total_msg_count, &brw_unread_msg_count); if (ret_code != JC_OK) { PRINT_INFORMATION_2(MMI_TRACE_INFO, "%s %u", "PUSH- Inside Push Inbox", ret_code); ASSERT(0); } /* While reading the messsage from idle screen when user will press back. at that time while displying the message list local buffer should clear Vivek - 12082006 */ mmi_brw_push_free_service_value_struct(&g_mmi_brw_push_cntx.current_service_message); g_mmi_brw_cntx.push_msg_rcvd_flag = MMI_FALSE; g_mmi_brw_push_cntx.push_delete_notification = MMI_FALSE; /* Display 'Empty' if no push messages are present */ if ((brw_total_msg_count) == 0) { DisplayPopup( (PU8) GetString(STR_GLOBAL_EMPTY), IMG_GLOBAL_EMPTY, 1, UI_POPUP_NOTIFYDURATION_TIME, EMPTY_LIST_TONE); /* Added by Vivek - 30july, 2006. If push inbox is open from the 'idle screen push indication'. After showing the empty pop up it should return to idle screen */ if (SCR_ID_BRW_NEW_PUSH_MESSAGE_IND == GetCurrScrnId()) { DeleteNHistory(1); } } else { EntryNewScreen(SCR_ID_BRW_SERVICE_INBOX, NULL, mmi_brw_entry_service_inbox, NULL); /* Added by Vivek - 11july, 2006. If push inbox is open from the 'idle screen push indication' */ if (SCR_ID_BRW_NEW_PUSH_MESSAGE_IND == GetCurrScrnId()) { DeleteNHistory(1); } guiBuffer = GetCurrGuiBuffer(SCR_ID_BRW_SERVICE_INBOX); mmi_brw_create_push_msg_list(); ShowCategory184Screen( STR_ID_BRW_SERVICE_INBOX, GetRootTitleIcon(SERVICES_WAP_MENU_ID), STR_GLOBAL_OPTIONS, 0, STR_GLOBAL_BACK, 0, brw_total_msg_count, mmi_brw_service_inbox_list_get_item, 0, 0, guiBuffer); SetLeftSoftkeyFunction(mmi_brw_highlighted_push_msg, KEY_EVENT_UP); SetKeyHandler(mmi_brw_highlighted_push_msg, KEY_RIGHT_ARROW, KEY_EVENT_DOWN); SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP); SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN); } }
/***************************************************************************** * FUNCTION * GoToServicesMenu * DESCRIPTION * Displays Services Menu * PARAMETERS * void * RETURNS * void *****************************************************************************/ void GoToServicesMenu(void) { /*----------------------------------------------------------------*/ /* Local Variables */ /*----------------------------------------------------------------*/ U16 nStrItemList[MAX_SUB_MENUS]; U16 nIconItemList[MAX_SUB_MENUS]; U8 *Strings[MAX_SUB_MENUS]; U16 Icons[MAX_SUB_MENUS]; U16 nNumofItem; U8 i = 0, j; U8 *guiBuffer; /*----------------------------------------------------------------*/ /* Code Body */ /*----------------------------------------------------------------*/ #ifdef __MMI_DUAL_SIM_MASTER__ if ((MTPNP_AD_Get_Status() != MTPNP_AD_CARD1) && (MTPNP_AD_Get_Status() != MTPNP_AD_CARD2) && (MTPNP_AD_Get_Status() != MTPNP_AD_DUALCARD)) { DisplayPopup( (PU8) GetString(SERVICES_NOT_PROVIDED_STRING_ID), IMG_GLOBAL_WARNING, 0, UI_POPUP_NOTIFYDURATION_TIME, (U8) WARNING_TONE); return; } #endif /* __MMI_DUAL_SIM_MASTER__ */ /* Retrieve no of child of menu item to be displayed */ nNumofItem = GetNumOfChild_Ext(MAIN_MENU_SERVICES_MENUID); /* Retrieve string ids in sequence of given menu item to be displayed */ GetSequenceStringIds_Ext(MAIN_MENU_SERVICES_MENUID, nStrItemList); GetSequenceImageIds_Ext(MAIN_MENU_SERVICES_MENUID, nIconItemList); #ifdef __SAT__ #if (defined __MMI_DUAL_SIM_SINGLE_CALL__) || (defined __MMI_DUAL_SIM_MASTER__) if ((IsSATPresent() && MTPNP_AD_Get_Status() == MTPNP_AD_CARD1) || (IsSATPresent() && MTPNP_AD_Get_Status() == MTPNP_AD_DUALCARD)) #else /* (defined __MMI_DUAL_SIM_SINGLE_CALL__) || (defined __MMI_DUAL_SIM_MASTER__) */ if (IsSATPresent()) #endif /* (defined __MMI_DUAL_SIM_SINGLE_CALL__) || (defined __MMI_DUAL_SIM_MASTER__) */ { Strings[0] = (mmi_ucs2strlen((S8*) gSATMainMenu.alphaId) == 0) ? (PU8) get_string(SAT_MENU_STRING_ID) : gSATMainMenu.alphaId; Icons[0] = SAT_TITLE_IMAGE_ID; i++; } #if (defined __MMI_DUAL_SIM_SINGLE_CALL__) || (defined __MMI_DUAL_SIM_MASTER__) if (IsSAT2Present() && IsSATPresent() && MTPNP_AD_Get_Status() == MTPNP_AD_DUALCARD) { Strings[1] = (mmi_ucs2strlen((S8*) gSATMainMenu.alphaId_2) == 0) ? (PU8) get_string(SAT_MENU_STRING_ID) : gSATMainMenu.alphaId_2; Icons[1] = SAT_TITLE_IMAGE_ID_2; i++; } else if ((IsSAT2Present() && MTPNP_AD_Get_Status() == MTPNP_AD_CARD2) || (IsSAT2Present() && !IsSATPresent() && MTPNP_AD_Get_Status() == MTPNP_AD_DUALCARD)) { Strings[0] = (mmi_ucs2strlen((S8*) gSATMainMenu.alphaId_2) == 0) ? (PU8) get_string(SAT_MENU_STRING_ID) : gSATMainMenu.alphaId_2; Icons[0] = SAT_TITLE_IMAGE_ID_2; i++; } #endif /* (defined __MMI_DUAL_SIM_SINGLE_CALL__) || (defined __MMI_DUAL_SIM_MASTER__) */ #endif /* __SAT__ */ for (j = 0; j < nNumofItem; j++) { if (isInfoNumPresent == 0 && nStrItemList[j] == SERVICES_INFO_NUM_STRING_ID) { continue; } Strings[i] = (PU8) GetString(nStrItemList[j]); Icons[i] = nIconItemList[j]; i++; } nNumofItem = i; #ifdef __MMI_MERGE_SAT_TO_MAINMENU__ if (nNumofItem == 0) { DisplayPopup((PU8) GetString(SERVICES_NOT_PROVIDED_STRING_ID), IMG_GLOBAL_ERROR, 0, 1000, ERROR_TONE); return; } else if (nNumofItem == 1 && IsSATPresent()) { GoToSATMainMenu(); return; } #endif /* __MMI_MERGE_SAT_TO_MAINMENU__ */ #ifdef __MMI_SERVICE_MENU_NUMERIC_LIST_ICON__ EntryNewScreen(SERVICES_MAIN_MENU_SCREEN_ID, wgui_restore_list_menu_slim_style, GoToServicesMenu, NULL); wgui_override_list_menu_slim_style(WGUI_LIST_MENU_SLIM_STYLE_NUMBER); #else /* __MMI_SERVICE_MENU_NUMERIC_LIST_ICON__ */ EntryNewScreen(SERVICES_MAIN_MENU_SCREEN_ID, NULL, GoToServicesMenu, NULL); #endif /* __MMI_SERVICE_MENU_NUMERIC_LIST_ICON__ */ SetParentHandler(MAIN_MENU_SERVICES_MENUID); guiBuffer = GetCurrGuiBuffer(SERVICES_MAIN_MENU_SCREEN_ID); RegisterHighlightHandler(ServicesMenuIndex); #ifdef __MMI_WGUI_MINI_TAB_BAR__ wgui_enable_mini_tab_bar(MAIN_MENU_SERVICES_MENUID); #endif ShowCategory84Screen( SERVICES_TITLE_STRING_ID, GetRootTitleIcon(MAIN_MENU_SERVICES_MENUID), STR_GLOBAL_OK, IMG_GLOBAL_OK, STR_GLOBAL_BACK, IMG_GLOBAL_BACK, nNumofItem, Strings, Icons, LIST_MENU, 0, guiBuffer); if (nNumofItem == 0) { /* No menu item and no SAT in GSM only project */ ChangeLeftSoftkey(0, 0); } SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP); SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN); }
void EntryBMIResultScreen(void) { //add by zough 061121 start U8 *guiBuffer; S8 calculatestr[OPERATOR_LEN+1]; S8 resultstr[OPERATOR_LEN+1]; S8 LBstr[OPERATOR_LEN+1]; S8 UBstr[OPERATOR_LEN+1]; CALOPERATOR_STRUCT LBValue; CALOPERATOR_STRUCT UBValue; CALOPERATOR_STRUCT calculate; CALOPERATOR_STRUCT result; U8 *bmiBuf; U8 percentageValue; U16 FolwerIndex; U8 LB, UB; S8 UnDispLen; memset(calculatestr, 0, OPERATOR_LEN+1); memset(resultstr, 0, OPERATOR_LEN+1); RateToStr(resultstr, &g_bmi_cntx->Weight); StrToRate(&result, resultstr); memset(&calculatestr, 0, OPERATOR_LEN+1); *calculatestr = '1'; *(calculatestr + 1) = '0'; *(calculatestr + 2) = '0'; *(calculatestr + 3) = '0'; *(calculatestr + 4) = '0'; StrToRate(&calculate, calculatestr); CalculatorMult(&result, &calculate); memset(g_bmi_cntx->ResultBuf, 0, sizeof(g_bmi_cntx->ResultBuf)); guiBuffer = GetCurrGuiBuffer(SCR_BMI_RESULT); EntryNewScreen(SCR_BMI_RESULT, NULL, EntryBMIResultScreen, NULL); memset(&calculatestr, 0, OPERATOR_LEN+1); RateToStr(calculatestr, &g_bmi_cntx->Height); StrToRate(&calculate, calculatestr); CalculatorDivi(&result, &calculate); memset(&calculatestr, 0, OPERATOR_LEN+1); RateToStr(calculatestr, &g_bmi_cntx->Height); StrToRate(&calculate, calculatestr); CalculatorDivi(&result, &calculate); RateToStr(resultstr, &result); //add by zough 061207 start if ((OPERATOR_LEN - 6) > 0) { for (UnDispLen = 6; UnDispLen <= OPERATOR_LEN; UnDispLen++) { *(resultstr + UnDispLen) = '\0'; } } //add by zough 061207 end // *(resultstr + OPERATOR_LEN) = '\0'; // *(resultstr + OPERATOR_LEN-1) = '\0'; AnsiiToUnicodeString((S8*)&g_bmi_cntx->ResultBuf, resultstr); if (g_bmi_cntx->Gender == 0) { LB = BMI_MALE_LB; UB = BMI_MALE_UB; FolwerIndex = IMG_BMI_BLUE_FLOWER; } else { LB = BMI_FEMALE_LB; UB = BMI_FEMALE_UB; FolwerIndex = IMG_BMI_RED_FLOWER; } coolsand_UI_itoa(LB, (U16*)g_bmi_cntx->LBBuf, 10); coolsand_UI_itoa(UB, (U16*)g_bmi_cntx->UBBuf, 10); UnicodeToAnsii(LBstr, g_bmi_cntx->LBBuf); UnicodeToAnsii(UBstr, g_bmi_cntx->UBBuf); StrToRate(&UBValue, UBstr); StrToRate(&LBValue, LBstr); if (CompFloat(&result, &UBValue) > 0) { bmiBuf = (U8*) GetString(STR_BMI_FAT); percentageValue = 2; } else if (CompFloat(&result, &LBValue) < 0) { bmiBuf = (U8*) GetString(STR_BMI_THIN); percentageValue = 0; } else { bmiBuf = (U8*) GetString(STR_BMI_NORMAL); percentageValue = 1; } ShowCategory122Screen(STR_BMI_RESULT_CAPTION, GetRootTitleIcon(ORGANIZER_HEALTH_MENU), 0, 0, STR_GLOBAL_BACK, IMG_GLOBAL_BACK, STR_BMI_BMI_TEXT, percentageValue, guiBuffer, g_bmi_cntx->ResultBuf, bmiBuf, FolwerIndex, (U8*)g_bmi_cntx->LBBuf, (U8*)g_bmi_cntx->UBBuf); SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP); //add by zough 061121 end }
void mmi_dialer_entry_screen(U16 scr_id, U16 left_softkey_id, U16 right_softkey_id, U8 *buffer, S32 buff_len) { /*----------------------------------------------------------------*/ /* Local Variables */ /*----------------------------------------------------------------*/ U8 *guiBuffer; S32 cnt; memset(CallBuffer, 0, sizeof(CallBuffer)); if (g_phb_cntx.phb_ready) { total_items = PhoneBookEntryCount; } else { total_items = 0; } if (!init_list_cell_text_array()) { return; } guiBuffer = GetCurrGuiBuffer(scr_id); RegisterCat200SearchFunction(my_search_func); RegisterHighlightHandler(mmi_dailer_word_hdlr); cnt = 0; input_buffer = (UI_string_type)buffer; input_buffer_len = buff_len; #if 0 //liping 2008-06-11 del // 第一次进入该窗口 if (guiBuffer == NULL) { memset(input_buffer, 0, input_buffer_len); } #endif //renchangming Bug #10121 待机界面输入号码进行保存时,左软键提示“保存”实际功能为拨号,提示与实际功能不符 2009-03-30 #ifdef __NEED_CHANGE_LEFT_KEY_TO_SENTER__ entry_new_dis_id_left_key_to_senter_init(); #endif menu_shortcut_handler_display = 1; ShowCategory658Screen( 0, 0, left_softkey_id, 0, right_softkey_id, 0, cnt, mmi_dailer_list_get_item, NULL, 0, 0, (U8*)input_buffer, input_buffer_len, guiBuffer); RegisterHighlightHandler(mmi_dailer_word_hdlr); SetCategory16RightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP); }
/***************************************************************************** * FUNCTION * EntryCHISTMainMenu * DESCRIPTION * Main screen of call history * NA * * PARAMETERS * void * RETURNS * void *****************************************************************************/ void EntryCHISTMainMenu(void) { /*----------------------------------------------------------------*/ /* Local Variables */ /*----------------------------------------------------------------*/ // U16 nDispAttribute; /* Stores display attribue */ U8 *guiBuffer; /* Buffer holding history data */ U16 nStrItemList[MAX_SUB_MENUS]; /* Stores the strings id of submenus returned */ U16 nNumofItem; /* Stores no of children in the submenu */ U16 ItemIcons[MAX_SUB_MENUS]; U8 *PopUpList[MAX_SUB_MENUS]; U16 LSKStr; U16 LSKImg; /*----------------------------------------------------------------*/ /* Code Body */ /*----------------------------------------------------------------*/ /* S32 maskingByte=-1; S32 menuItemId=-1; */ #ifdef __MMI_UI_SMALL_SCREEN_SUPPORT__ if (mmi_is_redrawing_bk_screens() == TRUE) { return; } #endif /* __MMI_UI_SMALL_SCREEN_SUPPORT__ */ /* Call Exit Handler */ #ifdef __MMI_CH_NUMERIC_LIST_ICON__ EntryNewScreen(SCR_CALL_HISTORY_MAIN_MENU, wgui_restore_list_menu_slim_style, EntryCHISTMainMenu, NULL); #else EntryNewScreen(SCR_CALL_HISTORY_MAIN_MENU, NULL, EntryCHISTMainMenu, NULL); #endif /* reset the indicies for dialed/recived/missed call list menus */ chis_p->currRecvdCallIndex = 0; chis_p->currMissedCallIndex = 0; chis_p->currDialedCallIndex = 0; /* Get current screen to gui buffer for history purposes */ guiBuffer = GetCurrGuiBuffer(SCR_CALL_HISTORY_MAIN_MENU); /* Retrieve no of child of menu item to be displayed */ nNumofItem = GetNumOfChild_Ext(MAIN_MENU_CALL_HISTORY); /* diamond, 2005/07/01 add _Ext to menu item functions */ /* Get attribute of menu to be displayed */ /* nDispAttribute = GetDispAttributeOfItem( MAIN_MENU_CALL_HISTORY ); */ /* Retrieve string/image ids in sequence of given menu item to be displayed */ GetSequenceStringIds_Ext(MAIN_MENU_CALL_HISTORY, nStrItemList); /* diamond, 2005/07/01 add _Ext to menu item functions */ GetSequenceImageIds_Ext(MAIN_MENU_CALL_HISTORY, ItemIcons); /* diamond, 2005/07/01 add _Ext to menu item functions */ /* Set current parent id */ SetParentHandler(MAIN_MENU_CALL_HISTORY); /* Register highlight handler to be called in menu screen */ RegisterHighlightHandler(ExecuteCurrHiliteHandler); /* diamond, 2005/07/01 removed for new menu item architecture to CPHS */ #if 0 /* under construction !*/ /* under construction !*/ /* under construction !*/ /* under construction !*/ /* under construction !*/ #endif /* 0 */ /* construct hint popup strings for menu items */ ConstructHintsList(MAIN_MENU_CALL_HISTORY, PopUpList); #ifdef __MMI_CH_NUMERIC_LIST_ICON__ wgui_override_list_menu_slim_style(WGUI_LIST_MENU_SLIM_STYLE_NUMBER); #endif /* MTK Leo add, mini_tab_bar */ #ifdef __MMI_WGUI_MINI_TAB_BAR__ wgui_enable_mini_tab_bar(MAIN_MENU_CALL_HISTORY); #endif /* MTK Leo end */ /* There may be no menu items in call log */ if (nNumofItem == 0) { LSKStr = 0; LSKImg = 0; } else { LSKStr = STR_GLOBAL_OK; LSKImg = IMG_GLOBAL_OK; } /* Display the call history main screen */ ShowCategory52Screen( #ifdef __MMI_DUAL_SIM_MASTER__ STRING_MTPNP_CARD1_CALL_HISTORY, #else /* __MMI_DUAL_SIM_MASTER__ */ STR_SCR_CALL_HISTORY_MAIN_MENU_CAPTION, #endif /* __MMI_DUAL_SIM_MASTER__ */ IMG_SCR_CALL_HISTORY_MAIN_MENU_CAPTION, LSKStr, LSKImg, STR_GLOBAL_BACK, IMG_GLOBAL_BACK, nNumofItem, nStrItemList, ItemIcons, (U8 **)PopUpList, 0, 0, /* u16callhist_curindex, */ guiBuffer); /* Register function with right softkey */ SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN); SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP); return; }
void EntryShowMTPNPHelpInfo(void) { MTPNP_UINT8 *guiBuffer; MTPNP_UINT8 tempbuf[MAX_TEST_STRING_BUF * 2]; MTPNP_UINT8 AsciiDisplayBuf[MAX_TEST_STRING_BUF]; ST_MTPNP_AD_VERSION mtpnp_version; EntryNewScreen(SCR_DMHELPINFO, MTPNP_NULL, EntryShowMTPNPHelpInfo, MTPNP_NULL); guiBuffer = GetCurrGuiBuffer(SCR_DMHELPINFO); SetParentHandler(MENU_MTPNP_HELPINFO); RegisterHighlightHandler(ExecuteCurrHiliteHandler); MTPNP_AD_Get_Revision(&mtpnp_version); MTPNP_OSAL_memset(UnicodeDisplayBuf, 0, sizeof(UnicodeDisplayBuf)); MTPNP_OSAL_memset(AsciiDisplayBuf, 0, sizeof(AsciiDisplayBuf)); MTPNP_PFAL_Ansii_To_Unicode_String((MTPNP_CHAR *) AsciiDisplayBuf, "[SDK master]"); MTPNP_PFAL_Unicode_String_Copy((MTPNP_CHAR *) UnicodeDisplayBuf, (const MTPNP_CHAR *) AsciiDisplayBuf); MTPNP_OSAL_memset(AsciiDisplayBuf, 0, sizeof(AsciiDisplayBuf)); sprintf((MTPNP_CHAR *) AsciiDisplayBuf, " %06d\n", (MTPNP_CHAR *) mtpnp_version.master_sdk_revision); MTPNP_OSAL_memset(tempbuf, 0, sizeof(tempbuf)); MTPNP_PFAL_Ansii_To_Unicode_String((MTPNP_CHAR *) tempbuf, (MTPNP_CHAR *) AsciiDisplayBuf); MTPNP_PFAL_Unicode_Strcat((MTPNP_CHAR *) UnicodeDisplayBuf, (const MTPNP_CHAR *) tempbuf); MTPNP_OSAL_memset(AsciiDisplayBuf, 0, sizeof(AsciiDisplayBuf)); MTPNP_PFAL_Ansii_To_Unicode_String((MTPNP_CHAR *) AsciiDisplayBuf, "[SDK slave]"); MTPNP_PFAL_Unicode_Strcat((MTPNP_CHAR *) UnicodeDisplayBuf, (const MTPNP_CHAR *) AsciiDisplayBuf); MTPNP_OSAL_memset(AsciiDisplayBuf, 0, sizeof(AsciiDisplayBuf)); sprintf((MTPNP_CHAR *) AsciiDisplayBuf, " %06d\n", (MTPNP_CHAR *) mtpnp_version.slave_sdk_revision); MTPNP_OSAL_memset(tempbuf, 0, sizeof(tempbuf)); MTPNP_PFAL_Ansii_To_Unicode_String((MTPNP_CHAR *) tempbuf, (MTPNP_CHAR *) AsciiDisplayBuf); MTPNP_PFAL_Unicode_Strcat((MTPNP_CHAR *) UnicodeDisplayBuf, (const MTPNP_CHAR *) tempbuf); MTPNP_OSAL_memset(AsciiDisplayBuf, 0, sizeof(AsciiDisplayBuf)); MTPNP_PFAL_Ansii_To_Unicode_String((MTPNP_CHAR *) AsciiDisplayBuf, "[AD master]"); MTPNP_PFAL_Unicode_Strcat((MTPNP_CHAR *) UnicodeDisplayBuf, (const MTPNP_CHAR *) AsciiDisplayBuf); MTPNP_OSAL_memset(AsciiDisplayBuf, 0, sizeof(AsciiDisplayBuf)); sprintf((MTPNP_CHAR *) AsciiDisplayBuf, " %06d\n", (S8 *) mtpnp_version.master_adapter_revision); MTPNP_OSAL_memset(tempbuf, 0, sizeof(tempbuf)); MTPNP_PFAL_Ansii_To_Unicode_String((MTPNP_CHAR *) tempbuf, (MTPNP_CHAR *) AsciiDisplayBuf); MTPNP_PFAL_Unicode_Strcat((MTPNP_CHAR *) UnicodeDisplayBuf, (const MTPNP_CHAR *) tempbuf); MTPNP_OSAL_memset(AsciiDisplayBuf, 0, sizeof(AsciiDisplayBuf)); MTPNP_PFAL_Ansii_To_Unicode_String((MTPNP_CHAR *) AsciiDisplayBuf, "[AD slave]"); MTPNP_PFAL_Unicode_Strcat((MTPNP_CHAR *) UnicodeDisplayBuf, (const MTPNP_CHAR *) AsciiDisplayBuf); MTPNP_OSAL_memset(AsciiDisplayBuf, 0, sizeof(AsciiDisplayBuf)); sprintf((MTPNP_CHAR *) AsciiDisplayBuf, " %06d\n", (MTPNP_CHAR *) mtpnp_version.slave_adapter_revision); MTPNP_OSAL_memset(tempbuf, 0, sizeof(tempbuf)); MTPNP_PFAL_Ansii_To_Unicode_String((MTPNP_CHAR *) tempbuf, (MTPNP_CHAR *) AsciiDisplayBuf); MTPNP_PFAL_Unicode_Strcat((MTPNP_CHAR *) UnicodeDisplayBuf, (const MTPNP_CHAR *) tempbuf); MTPNP_OSAL_memset(AsciiDisplayBuf, 0, sizeof(AsciiDisplayBuf)); MTPNP_PFAL_Ansii_To_Unicode_String((MTPNP_CHAR *) AsciiDisplayBuf, "[Register state]"); MTPNP_PFAL_Unicode_Strcat((MTPNP_CHAR *) UnicodeDisplayBuf, (const MTPNP_CHAR *) AsciiDisplayBuf); MTPNP_OSAL_memset(AsciiDisplayBuf, 0, sizeof(AsciiDisplayBuf)); if (MTPNP_AD_SW_Need_Register()) { sprintf((MTPNP_CHAR *) AsciiDisplayBuf, " Unregistered\n"); } else { sprintf((MTPNP_CHAR *) AsciiDisplayBuf, " Registered\n"); } MTPNP_OSAL_memset(tempbuf, 0, sizeof(tempbuf)); MTPNP_PFAL_Ansii_To_Unicode_String((MTPNP_CHAR *) tempbuf, (MTPNP_CHAR *) AsciiDisplayBuf); MTPNP_PFAL_Unicode_Strcat((MTPNP_CHAR *) UnicodeDisplayBuf, (const MTPNP_CHAR *) tempbuf); MTPNP_OSAL_memset(AsciiDisplayBuf, 0, sizeof(AsciiDisplayBuf)); MTPNP_PFAL_Ansii_To_Unicode_String((MTPNP_CHAR *) AsciiDisplayBuf, "[Register code]\n"); MTPNP_PFAL_Unicode_Strcat((MTPNP_CHAR *) UnicodeDisplayBuf, (const MTPNP_CHAR *) AsciiDisplayBuf); MTPNP_OSAL_memset(AsciiDisplayBuf, 0, sizeof(AsciiDisplayBuf)); sprintf((MTPNP_CHAR *) AsciiDisplayBuf, " %s\n", (MTPNP_CHAR *) mtpnp_version.register_value); MTPNP_OSAL_memset(tempbuf, 0, sizeof(tempbuf)); MTPNP_PFAL_Ansii_To_Unicode_String((MTPNP_CHAR *) tempbuf, (MTPNP_CHAR *) AsciiDisplayBuf); MTPNP_PFAL_Unicode_Strcat((MTPNP_CHAR *) UnicodeDisplayBuf, (const MTPNP_CHAR *) tempbuf); if (MTPNP_AD_SW_Need_Register()) { ShowCategory74Screen(STRING_MTPNP_HELPINFO, 0, STRING_MTPNP_REGISTER, 0, STR_GLOBAL_BACK, 0, (MTPNP_UINT8 *) UnicodeDisplayBuf, sizeof(UnicodeDisplayBuf), guiBuffer); SetLeftSoftkeyFunction(EntryRegisterSW, KEY_EVENT_UP); SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP); } else { ShowCategory74Screen(STRING_MTPNP_HELPINFO, 0, (MTPNP_UINT16) NULL, 0, STR_GLOBAL_BACK, 0, (MTPNP_UINT8 *) UnicodeDisplayBuf, sizeof(UnicodeDisplayBuf), guiBuffer); SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP); } }
/***************************************************************************** * FUNCTION * EntrySpofApp * DESCRIPTION * Entry function of schedule power on off application. * PARAMETERS * None. * RETURNS * None. * GLOBALS AFFECTED * None *****************************************************************************/ void EntrySpofApp(void) { U8* guiBuffer; S32 i; S32 num_of_items = NUM_OF_SPOF; MYTIME tmpTime; U16 spof_states_icon[NUM_OF_SPOF]; U16 spof_type_icon[NUM_OF_SPOF]; #ifdef __MMI_TWO_SPOF__ num_of_items = 2; #endif EntryNewScreen(SCR_ID_SPOF_APP, NULL, EntrySpofApp, NULL); guiBuffer = GetCurrGuiBuffer(SCR_ID_SPOF_APP); if(guiBuffer == NULL) g_spof_cntx.CurrItem = 0; /* initialize list to display */ for (i=0;i<NUM_OF_SPOF;i++) { /* get the value of spof_list*/ memset(&tmpTime,0,sizeof(MYTIME)); tmpTime.nHour = g_spof_cntx.SPOFList[i].Hour; tmpTime.nMin = g_spof_cntx.SPOFList[i].Min; time_string(&tmpTime,(UI_string_type)subMenuDataPtrs[i],DT_IDLE_SCREEN); /* get the value of spof_vicons*/ #if defined(__PROJECT_GALLITE_C01__) if(g_spof_cntx.SPOFList[i].Status == SPOF_DISABLE) spof_states_icon[i] = IMG_VICON; else { /*get the value of spof_type poweon off */ if(g_spof_cntx.SPOFList[i].Type == SPOF_POWERON) spof_states_icon[i] = SPOF_TYPEPOWERON_IMAGEID; else spof_states_icon[i] = SPOF_TYPEPOWEROFF_IMAGEID; } #else if(g_spof_cntx.SPOFList[i].Status == SPOF_DISABLE) spof_states_icon[i] = SPOF_BLANK_IMAGEID; else spof_states_icon[i] = IMG_VICON; #endif /*get the value of spof_type poweon off */ if(g_spof_cntx.SPOFList[i].Type == SPOF_POWERON) spof_type_icon[i] = SPOF_TYPEPOWERON_IMAGEID; else spof_type_icon[i] = SPOF_TYPEPOWEROFF_IMAGEID; } ShowCategory73Screen(SPOF_MAIN_TITLE_STRINGID,IMG_SCR_SETTING_CAPTION,STR_GLOBAL_EDIT, SPOF_EDIT_BUTTON_IMAGEID,STR_GLOBAL_BACK,IMG_GLOBAL_BACK,num_of_items,subMenuDataPtrs, spof_states_icon,spof_type_icon, 0,guiBuffer,1); RegisterHighlightHandler(HighlightSpofList); SetLeftSoftkeyFunction(EntrySpofEdit,KEY_EVENT_UP); SetKeyHandler(EntrySpofEdit, KEY_RIGHT_ARROW,KEY_EVENT_DOWN); SetRightSoftkeyFunction(GoBackHistory,KEY_EVENT_UP); SetKeyHandler(GoBackHistory,KEY_LEFT_ARROW,KEY_EVENT_DOWN); }
/***************************************************************************** * FUNCTION * mmi_vrsdscut_entry_list * DESCRIPTION * This function is just for template. * PARAMETERS * void * a(?) [IN/OUT] First variable, used as returns * b(?) [IN] Second variable * RETURNS * the description of return value, if any.(?) *****************************************************************************/ void mmi_vrsdscut_entry_list(void) { /*----------------------------------------------------------------*/ /* Local Variables */ /*----------------------------------------------------------------*/ U8 i; U8 *guiBuffer; U16 ShctCandList[SHCT_MAX_CANDI_LIST]; /* All shortcut candidate */ U16 ImageList[SHCT_MAX_CANDI_LIST]; vrsd_tag_struct tag_list[MMI_VRSD_MAX_TAG]; S16 pError; /*----------------------------------------------------------------*/ /* Code Body */ /*----------------------------------------------------------------*/ EntryNewScreen(SCR_ID_VRSD_SHORTCUT_LIST, NULL, mmi_vrsdscut_entry_list, NULL); guiBuffer = GetCurrGuiBuffer(SCR_ID_VRSD_SHORTCUT_LIST); /* Read Voice Tag List */ ReadRecord(NVRAM_EF_VRSD_TAG_LID, 1, (void*)tag_list, MMI_VRSD_MAX_TAG * sizeof(vrsd_tag_struct), &pError); /* Assign shortcut string and image */ for (i = 0; i < g_shct_cntx.NumCandShct; i++) { ShctCandList[i] = ShctGetStringID(g_shct_cntx.CandShctList[i]); /* Check if shortcut item has voice tag */ if (mmi_vrsd_util_get_tag_id_in_list(MMI_VRSD_APP_SHORTCUT, i, tag_list) != 0xffff) { ImageList[i] = IMG_ID_VRSD_APP; } else { ImageList[i] = IMG_ID_VRSD_SHORTCUT; } } if (guiBuffer == NULL) { g_vrsdscut_highlight = 0; } RegisterHighlightHandler(mmi_vrsdscut_list_highlight_hdlr); ShowCategory15Screen( STR_ID_VRSD_SHORTCUT, MAIN_MENU_TITLE_MULTIMEDIA_ICON, STR_GLOBAL_OPTIONS, IMG_GLOBAL_OPTIONS, STR_GLOBAL_BACK, IMG_GLOBAL_BACK, g_shct_cntx.NumCandShct, ShctCandList, (U16*) ImageList, LIST_MENU, g_vrsdscut_highlight, guiBuffer); SetLeftSoftkeyFunction(mmi_vrsdscut_entry_tag_option, KEY_EVENT_UP); SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP); SetKeyHandler(mmi_vrsdscut_entry_tag_option, KEY_RIGHT_ARROW, KEY_EVENT_DOWN); SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN); }