PoCGroups.c
资源名称:mmi.rar [点击查看]
上传用户:lqx1163
上传日期:2014-08-13
资源大小:9183k
文件大小:363k
源码类别:
MTK
开发平台:
C/C++
- /*****************************************************************************
- * Copyright Statement:
- * --------------------
- * This software is protected by Copyright and the information contained
- * herein is confidential. The software may not be copied and the information
- * contained herein may not be used or disclosed except with the written
- * permission of MediaTek Inc. (C) 2005
- *
- * BY OPENING THIS FILE, BUYER HEREBY UNEQUIVOCALLY ACKNOWLEDGES AND AGREES
- * THAT THE SOFTWARE/FIRMWARE AND ITS DOCUMENTATIONS ("MEDIATEK SOFTWARE")
- * RECEIVED FROM MEDIATEK AND/OR ITS REPRESENTATIVES ARE PROVIDED TO BUYER ON
- * AN "AS-IS" BASIS ONLY. MEDIATEK EXPRESSLY DISCLAIMS ANY AND ALL WARRANTIES,
- * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE IMPLIED WARRANTIES OF
- * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE OR NONINFRINGEMENT.
- * NEITHER DOES MEDIATEK PROVIDE ANY WARRANTY WHATSOEVER WITH RESPECT TO THE
- * SOFTWARE OF ANY THIRD PARTY WHICH MAY BE USED BY, INCORPORATED IN, OR
- * SUPPLIED WITH THE MEDIATEK SOFTWARE, AND BUYER AGREES TO LOOK ONLY TO SUCH
- * THIRD PARTY FOR ANY WARRANTY CLAIM RELATING THERETO. MEDIATEK SHALL ALSO
- * NOT BE RESPONSIBLE FOR ANY MEDIATEK SOFTWARE RELEASES MADE TO BUYER'S
- * SPECIFICATION OR TO CONFORM TO A PARTICULAR STANDARD OR OPEN FORUM.
- *
- * BUYER'S SOLE AND EXCLUSIVE REMEDY AND MEDIATEK'S ENTIRE AND CUMULATIVE
- * LIABILITY WITH RESPECT TO THE MEDIATEK SOFTWARE RELEASED HEREUNDER WILL BE,
- * AT MEDIATEK'S OPTION, TO REVISE OR REPLACE THE MEDIATEK SOFTWARE AT ISSUE,
- * OR REFUND ANY SOFTWARE LICENSE FEES OR SERVICE CHARGE PAID BY BUYER TO
- * MEDIATEK FOR SUCH MEDIATEK SOFTWARE AT ISSUE.
- *
- * THE TRANSACTION CONTEMPLATED HEREUNDER SHALL BE CONSTRUED IN ACCORDANCE
- * WITH THE LAWS OF THE STATE OF CALIFORNIA, USA, EXCLUDING ITS CONFLICT OF
- * LAWS PRINCIPLES. ANY DISPUTES, CONTROVERSIES OR CLAIMS ARISING THEREOF AND
- * RELATED THERETO SHALL BE SETTLED BY ARBITRATION IN SAN FRANCISCO, CA, UNDER
- * THE RULES OF THE INTERNATIONAL CHAMBER OF COMMERCE (ICC).
- *
- *****************************************************************************/
- /*****************************************************************************
- *
- * Filename:
- * ---------
- * PoCGroups.c
- *
- * Project:
- * --------
- * MAUI
- *
- * Description:
- * ------------
- * This file implements poc groups
- *
- * Author:
- * -------
- * -------
- *
- ==============================================================
- * HISTORY
- * Below this line, this part is controlled by PVCS VM. DO NOT MODIFY!!
- *------------------------------------------------------------------------------
- * removed!
- * removed!
- * removed!
- *
- * removed!
- * removed!
- * removed!
- *
- * removed!
- * removed!
- * removed!
- *
- * removed!
- * removed!
- * removed!
- *
- * removed!
- * removed!
- * removed!
- *
- * removed!
- * removed!
- * removed!
- *
- * removed!
- * removed!
- * removed!
- *
- * removed!
- * removed!
- * removed!
- *
- * removed!
- * removed!
- * removed!
- *
- * removed!
- * removed!
- * removed!
- *
- * removed!
- * removed!
- * removed!
- *
- * removed!
- * removed!
- * removed!
- *
- *------------------------------------------------------------------------------
- * Upper this line, this part is controlled by PVCS VM. DO NOT MODIFY!!
- *=============================================================
- *******************************************************************************/
- #include "MMI_features.h"
- #ifdef __MMI_POC__
- #ifndef __MTK_TARGET__
- #include <Windows.h>
- #endif
- #include "stdC.h"
- #include "L4Dr1.h"
- #include "mdi_datatype.h"
- #include "DebugInitDef.h"
- #include "mmi_trc.h" /* debug info */
- #include "GlobalMenuItems.h"
- #include "CustMenuRes.h"
- #include "CustDataRes.h"
- #include "ProtocolEvents.h"
- #include "CommonScreens.h"
- #include "EventsGprot.h"
- #include "SettingProfile.h"
- #include "wgui_categories_popup.h"
- #include "wgui_categories_inputs.h"
- #include "ProfileGprots.h"
- #include "CallSetup.h"
- #include "NVRAMEnum.h"
- #include "NVRAMProt.h"
- #include "NVRAMType.h"
- #include "custom_nvram_editor_data_item.h"
- #include "custom_data_account.h"
- #include "DataAccountGProt.h"
- #include "sip_msg_api.h"
- #include "sip_ua_api.h"
- #include "app2soc_struct.h"
- #include "soc_api.h"
- #include "app2sip_struct.h"
- #include "app2xdm_struct.h"
- #include "mmi2poc_struct.h"
- #include "custom_poc_config.h"
- #include "PoCGprot.h"
- #include "PoCProt.h"
- #include "app2xdm_enums.h"
- #include "wgui_tab_bars.h"
- #include "wgui_categories_IMPS.h"
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_highlight_contact
- * DESCRIPTION
- * Highlight handler of PoC menu
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_highlight_contact(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- SetLeftSoftkeyFunction(mmi_poc_entry_contact, KEY_EVENT_UP);
- SetKeyHandler(mmi_poc_entry_contact, KEY_RIGHT_ARROW, KEY_EVENT_DOWN);
- SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP);
- SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_highlight_contact_opt
- * DESCRIPTION
- * Highlight handler of PoC menu
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_highlight_contact_opt(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- SetLeftSoftkeyFunction(mmi_poc_entry_contact_opt, KEY_EVENT_UP);
- SetKeyHandler(mmi_poc_entry_contact_opt, KEY_RIGHT_ARROW, KEY_EVENT_DOWN);
- SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP);
- SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_highlight_contact_opt_settings
- * DESCRIPTION
- * Highlight handler of PoC menu
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_highlight_contact_opt_settings(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- SetLeftSoftkeyFunction(mmi_poc_entry_contact_opt_settings, KEY_EVENT_UP);
- SetKeyHandler(mmi_poc_entry_contact_opt_settings, KEY_RIGHT_ARROW, KEY_EVENT_DOWN);
- SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP);
- SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_highlight_contact_opt_settings_modify
- * DESCRIPTION
- * Highlight handler of PoC menu
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_highlight_contact_opt_settings_modify(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- SetLeftSoftkeyFunction(mmi_poc_entry_contact_opt_settings_modify, KEY_EVENT_UP);
- SetKeyHandler(0, KEY_RIGHT_ARROW, KEY_EVENT_DOWN);
- SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP);
- SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_highlight_contact_opt_settings_add
- * DESCRIPTION
- * Highlight handler of PoC menu
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_highlight_contact_opt_settings_add(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- SetLeftSoftkeyFunction(mmi_poc_entry_contact_opt_settings_add, KEY_EVENT_UP);
- SetKeyHandler(0, KEY_RIGHT_ARROW, KEY_EVENT_DOWN);
- SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP);
- SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_highlight_contact_opt_settings_delete
- * DESCRIPTION
- * Highlight handler of PoC menu
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_highlight_contact_opt_settings_delete(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- SetLeftSoftkeyFunction(mmi_poc_entry_contact_opt_settings_delete_cfrm, KEY_EVENT_UP);
- SetKeyHandler(0, KEY_RIGHT_ARROW, KEY_EVENT_DOWN);
- SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP);
- SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_highlight_contact_opt_settings_info
- * DESCRIPTION
- * Highlight handler of PoC menu
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_highlight_contact_opt_settings_info(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- SetLeftSoftkeyFunction(mmi_poc_entry_contact_opt_settings_info, KEY_EVENT_UP);
- SetKeyHandler(mmi_poc_entry_contact_opt_settings_info, KEY_RIGHT_ARROW, KEY_EVENT_DOWN);
- SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP);
- SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_highlight_contact_opt_settings_attributes_allow_invite
- * DESCRIPTION
- * Highlight handler of PoC menu
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_highlight_contact_opt_settings_attributes_allow_invite(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- SetLeftSoftkeyFunction(mmi_poc_entry_contact_opt_settings_attributes_allow_invite, KEY_EVENT_UP);
- SetKeyHandler(0, KEY_RIGHT_ARROW, KEY_EVENT_DOWN);
- SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP);
- SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_highlight_contact_opt_settings_attributes_allow_invite_accept
- * DESCRIPTION
- * Highlight handler of PoC menu
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_highlight_contact_opt_settings_attributes_allow_invite_accept(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- SetLeftSoftkeyFunction(mmi_poc_contact_set_allow_invite_accept, KEY_EVENT_UP);
- SetKeyHandler(0, KEY_RIGHT_ARROW, KEY_EVENT_DOWN);
- SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP);
- SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_highlight_contact_opt_settings_attributes_allow_invite_auto
- * DESCRIPTION
- * Highlight handler of PoC menu
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_highlight_contact_opt_settings_attributes_allow_invite_auto(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- SetLeftSoftkeyFunction(mmi_poc_contact_set_allow_invite_auto, KEY_EVENT_UP);
- SetKeyHandler(0, KEY_RIGHT_ARROW, KEY_EVENT_DOWN);
- SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP);
- SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_highlight_contact_opt_settings_attributes_allow_invite_reject
- * DESCRIPTION
- * Highlight handler of PoC menu
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_highlight_contact_opt_settings_attributes_allow_invite_reject(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- SetLeftSoftkeyFunction(mmi_poc_contact_set_allow_invite_reject, KEY_EVENT_UP);
- SetKeyHandler(0, KEY_RIGHT_ARROW, KEY_EVENT_DOWN);
- SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP);
- SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_highlight_contact_opt_settings_attributes_allow_subscribe
- * DESCRIPTION
- * Highlight handler of PoC menu
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_highlight_contact_opt_settings_attributes_allow_subscribe(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- SetLeftSoftkeyFunction(mmi_poc_entry_allow_subscribe, KEY_EVENT_UP);
- SetKeyHandler(0, KEY_RIGHT_ARROW, KEY_EVENT_DOWN);
- SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP);
- SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_highlight_contact_opt_settings_attributes_allow_subscribe_block
- * DESCRIPTION
- * Highlight handler of PoC menu
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_highlight_contact_opt_settings_attributes_allow_subscribe_block(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- SetLeftSoftkeyFunction(mmi_poc_entry_allow_subscribe_block, KEY_EVENT_UP);
- SetKeyHandler(0, KEY_RIGHT_ARROW, KEY_EVENT_DOWN);
- SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP);
- SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_highlight_contact_opt_settings_attributes_allow_subscribe_polite_block
- * DESCRIPTION
- * Highlight handler of PoC menu
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_highlight_contact_opt_settings_attributes_allow_subscribe_polite_block(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- SetLeftSoftkeyFunction(mmi_poc_entry_allow_subscribe_polite_block, KEY_EVENT_UP);
- SetKeyHandler(0, KEY_RIGHT_ARROW, KEY_EVENT_DOWN);
- SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP);
- SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_highlight_contact_opt_settings_attributes_allow_subscribe_allow
- * DESCRIPTION
- * Highlight handler of PoC menu
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_highlight_contact_opt_settings_attributes_allow_subscribe_allow(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- SetLeftSoftkeyFunction(mmi_poc_entry_allow_subscribe_allow, KEY_EVENT_UP);
- SetKeyHandler(0, KEY_RIGHT_ARROW, KEY_EVENT_DOWN);
- SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP);
- SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_highlight_contact_opt_settings_attributes_provide_pres
- * DESCRIPTION
- * Highlight handler of PoC menu
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_highlight_contact_opt_settings_attributes_provide_pres(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- SetLeftSoftkeyFunction(mmi_poc_entry_contact_opt_settings_attributes_provide_pres, KEY_EVENT_UP);
- SetKeyHandler(mmi_poc_entry_contact_opt_settings_attributes_provide_pres, KEY_RIGHT_ARROW, KEY_EVENT_DOWN);
- SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP);
- SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_highlight_contact_opt_settings_attributes_subscribe_pres
- * DESCRIPTION
- * Highlight handler of PoC menu
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_highlight_contact_opt_settings_attributes_subscribe_pres(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- SetLeftSoftkeyFunction(mmi_poc_contact_set_subscribe_pres, KEY_EVENT_UP);
- SetKeyHandler(0, KEY_RIGHT_ARROW, KEY_EVENT_DOWN);
- SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP);
- SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_highlight_contact_opt_send_alert
- * DESCRIPTION
- * Highlight handler of PoC menu
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_highlight_contact_opt_send_alert(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- SetLeftSoftkeyFunction(mmi_poc_entry_contact_opt_send_alert, KEY_EVENT_UP);
- SetKeyHandler(0, KEY_RIGHT_ARROW, KEY_EVENT_DOWN);
- SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP);
- SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_highlight_contact_opt_adhoc_talk
- * DESCRIPTION
- * Highlight handler of PoC menu
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_highlight_contact_opt_adhoc_talk(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- SetLeftSoftkeyFunction(mmi_poc_entry_contact_opt_adhoc_talk, KEY_EVENT_UP);
- SetKeyHandler(0, KEY_RIGHT_ARROW, KEY_EVENT_DOWN);
- SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP);
- SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_highlight_contact_opt_refresh_status
- * DESCRIPTION
- * Highlight handler of PoC menu
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_highlight_contact_opt_refresh_status(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- SetLeftSoftkeyFunction(mmi_poc_contact_send_refresh_status, KEY_EVENT_UP);
- SetKeyHandler(0, KEY_RIGHT_ARROW, KEY_EVENT_DOWN);
- SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP);
- SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_highlight_talk_groups
- * DESCRIPTION
- * Highlight handler of PoC menu
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_highlight_talk_groups(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- SetLeftSoftkeyFunction(mmi_poc_entry_talk_groups, KEY_EVENT_UP);
- SetKeyHandler(mmi_poc_entry_talk_groups, KEY_RIGHT_ARROW, KEY_EVENT_DOWN);
- SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP);
- SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_highlight_talk_groups_opt
- * DESCRIPTION
- * Highlight handler of PoC menu
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_highlight_talk_groups_opt(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- SetLeftSoftkeyFunction(mmi_poc_entry_talk_groups_opt, KEY_EVENT_UP);
- SetKeyHandler(mmi_poc_entry_talk_groups_opt, KEY_RIGHT_ARROW, KEY_EVENT_DOWN);
- SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP);
- SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_highlight_talk_groups_opt_entry_settings
- * DESCRIPTION
- * Highlight handler of PoC menu
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_highlight_talk_groups_opt_entry_settings(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- SetLeftSoftkeyFunction(mmi_poc_entry_talk_groups_opt_entry_settings, KEY_EVENT_UP);
- SetKeyHandler(mmi_poc_entry_talk_groups_opt_entry_settings, KEY_RIGHT_ARROW, KEY_EVENT_DOWN);
- SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP);
- SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_highlight_talk_groups_opt_entry_settings_add
- * DESCRIPTION
- * Highlight handler of PoC menu
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_highlight_talk_groups_opt_entry_settings_add(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- SetLeftSoftkeyFunction(mmi_poc_entry_talk_groups_opt_entry_settings_add, KEY_EVENT_UP);
- SetKeyHandler(0, KEY_RIGHT_ARROW, KEY_EVENT_DOWN);
- SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP);
- SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_highlight_talk_groups_opt_entry_settings_add_from_contact
- * DESCRIPTION
- * Highlight handler of PoC menu
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_highlight_talk_groups_opt_entry_settings_add_from_contact(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- SetLeftSoftkeyFunction(mmi_poc_entry_talk_groups_opt_entry_settings_add_from_contact, KEY_EVENT_UP);
- SetKeyHandler(0, KEY_RIGHT_ARROW, KEY_EVENT_DOWN);
- SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP);
- SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_highlight_talk_groups_opt_entry_settings_delete
- * DESCRIPTION
- * Highlight handler of PoC menu
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_highlight_talk_groups_opt_entry_settings_delete(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- SetLeftSoftkeyFunction(mmi_poc_talk_groups_opt_entry_delete_cfrm, KEY_EVENT_UP);
- SetKeyHandler(0, KEY_RIGHT_ARROW, KEY_EVENT_DOWN);
- SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP);
- SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_highlight_talk_groups_opt_entry_settings_entry_info
- * DESCRIPTION
- * Highlight handler of PoC menu
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_highlight_talk_groups_opt_entry_settings_entry_info(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- SetLeftSoftkeyFunction(mmi_poc_entry_talk_groups_opt_entry_settings_entry_info, KEY_EVENT_UP);
- SetKeyHandler(0, KEY_RIGHT_ARROW, KEY_EVENT_DOWN);
- SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP);
- SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_highlight_talk_groups_opt_entry_settings_entry_attributes_conf_state
- * DESCRIPTION
- * Highlight handler of PoC menu
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_highlight_talk_groups_opt_entry_settings_entry_attributes_conf_state(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- SetLeftSoftkeyFunction(mmi_poc_talk_group_set_conf_state, KEY_EVENT_UP);
- SetKeyHandler(0, KEY_RIGHT_ARROW, KEY_EVENT_DOWN);
- SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP);
- SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_highlight_talk_groups_opt_entry_settings_entry_attributes_invite_user_dyna
- * DESCRIPTION
- * Highlight handler of PoC menu
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_highlight_talk_groups_opt_entry_settings_entry_attributes_invite_user_dyna(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- SetLeftSoftkeyFunction(mmi_poc_talk_group_set_invite_user_dyna, KEY_EVENT_UP);
- SetKeyHandler(0, KEY_RIGHT_ARROW, KEY_EVENT_DOWN);
- SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP);
- SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_highlight_talk_groups_opt_entry_settings_entry_attributes_join_handling
- * DESCRIPTION
- * Highlight handler of PoC menu
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_highlight_talk_groups_opt_entry_settings_entry_attributes_join_handling(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- SetLeftSoftkeyFunction(mmi_poc_talk_group_set_join_handling, KEY_EVENT_UP);
- SetKeyHandler(0, KEY_RIGHT_ARROW, KEY_EVENT_DOWN);
- SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP);
- SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_highlight_talk_groups_opt_entry_settings_entry_attributes_init_conf
- * DESCRIPTION
- * Highlight handler of PoC menu
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_highlight_talk_groups_opt_entry_settings_entry_attributes_init_conf(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- SetLeftSoftkeyFunction(mmi_poc_talk_group_set_init_conf, KEY_EVENT_UP);
- SetKeyHandler(0, KEY_RIGHT_ARROW, KEY_EVENT_DOWN);
- SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP);
- SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_highlight_talk_groups_opt_entry_settings_entry_attributes_anonymity
- * DESCRIPTION
- * Highlight handler of PoC menu
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_highlight_talk_groups_opt_entry_settings_entry_attributes_anonymity(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- SetLeftSoftkeyFunction(mmi_poc_talk_group_set_anonymity, KEY_EVENT_UP);
- SetKeyHandler(0, KEY_RIGHT_ARROW, KEY_EVENT_DOWN);
- SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP);
- SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_highlight_talk_groups_opt_add_group
- * DESCRIPTION
- * Highlight handler of PoC menu
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_highlight_talk_groups_opt_add_group(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- SetLeftSoftkeyFunction(mmi_poc_entry_talk_groups_opt_add_group, KEY_EVENT_UP);
- SetKeyHandler(0, KEY_RIGHT_ARROW, KEY_EVENT_DOWN);
- SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP);
- SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_highlight_talk_groups_opt_delete_group
- * DESCRIPTION
- * Highlight handler of PoC menu
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_highlight_talk_groups_opt_delete_group(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- SetLeftSoftkeyFunction(mmi_poc_entry_talk_group_opt_delete_cfrm, KEY_EVENT_UP);
- SetKeyHandler(0, KEY_RIGHT_ARROW, KEY_EVENT_DOWN);
- SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP);
- SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_highlight_talk_groups_opt_group_info
- * DESCRIPTION
- * Highlight handler of PoC menu
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_highlight_talk_groups_opt_group_info(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- SetLeftSoftkeyFunction(mmi_poc_entry_talk_groups_opt_group_info, KEY_EVENT_UP);
- SetKeyHandler(0, KEY_RIGHT_ARROW, KEY_EVENT_DOWN);
- SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP);
- SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_highlight_talk_groups_info_entry_attributes_conf_state
- * DESCRIPTION
- * Highlight handler of PoC menu
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_highlight_talk_groups_info_entry_attributes_conf_state(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- SetLeftSoftkeyFunction(mmi_poc_talk_group_set_default_conf_state, KEY_EVENT_UP);
- SetKeyHandler(0, KEY_RIGHT_ARROW, KEY_EVENT_DOWN);
- SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP);
- SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_highlight_talk_groups_info_entry_attributes_invite_user_dyna
- * DESCRIPTION
- * Highlight handler of PoC menu
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_highlight_talk_groups_info_entry_attributes_invite_user_dyna(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- SetLeftSoftkeyFunction(mmi_poc_talk_group_set_default_invite_user_dyna, KEY_EVENT_UP);
- SetKeyHandler(0, KEY_RIGHT_ARROW, KEY_EVENT_DOWN);
- SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP);
- SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_highlight_talk_groups_info_entry_attributes_join_handling
- * DESCRIPTION
- * Highlight handler of PoC menu
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_highlight_talk_groups_info_entry_attributes_join_handling(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- SetLeftSoftkeyFunction(mmi_poc_talk_group_set_default_join_handling, KEY_EVENT_UP);
- SetKeyHandler(0, KEY_RIGHT_ARROW, KEY_EVENT_DOWN);
- SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP);
- SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_highlight_talk_groups_info_entry_attributes_init_conf
- * DESCRIPTION
- * Highlight handler of PoC menu
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_highlight_talk_groups_info_entry_attributes_init_conf(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- SetLeftSoftkeyFunction(mmi_poc_talk_group_set_default_init_conf, KEY_EVENT_UP);
- SetKeyHandler(0, KEY_RIGHT_ARROW, KEY_EVENT_DOWN);
- SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP);
- SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_highlight_talk_groups_info_entry_attributes_anonymity
- * DESCRIPTION
- * Highlight handler of PoC menu
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_highlight_talk_groups_info_entry_attributes_anonymity(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- SetLeftSoftkeyFunction(mmi_poc_talk_group_set_default_anonymity, KEY_EVENT_UP);
- SetKeyHandler(0, KEY_RIGHT_ARROW, KEY_EVENT_DOWN);
- SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP);
- SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_highlight_talk_groups_opt_call_others_group
- * DESCRIPTION
- * Highlight handler of PoC menu
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_highlight_talk_groups_opt_call_others_group(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- SetLeftSoftkeyFunction(mmi_poc_entry_talk_groups_opt_call_others_group, KEY_EVENT_UP);
- SetKeyHandler(0, KEY_RIGHT_ARROW, KEY_EVENT_DOWN);
- SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP);
- SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_hint_allow_invite
- * DESCRIPTION
- * Hint handler of PoC menu
- * PARAMETERS
- * index [IN]
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_hint_allow_invite(U16 index)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- memset((S8*) hintData[(index)], 0, MAX_SUB_MENU_SIZE);
- switch (g_poc_cntx_p->contact_entry_disp.allow_invite)
- {
- case POC_SETTING_TRUE:
- pfnUnicodeStrcpy((S8*) hintData[index], (PS8) GetString(STR_ID_POC_MANUAL_ANS));
- break;
- case POC_SETTING_FALSE:
- pfnUnicodeStrcpy((S8*) hintData[index], (PS8) GetString(STR_ID_POC_REJECT));
- break;
- case POC_SETTING_ACCEPT:
- pfnUnicodeStrcpy((S8*) hintData[index], (PS8) GetString(STR_ID_POC_AUTO_ACCEPT));
- break;
- default:
- pfnUnicodeStrcpy((S8*) hintData[index], (PS8) GetString(STR_GLOBAL_EMPTY));
- break;
- }
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_hint_allow_subscribe
- * DESCRIPTION
- * Hint handler of PoC menu
- * PARAMETERS
- * index [IN]
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_hint_allow_subscribe(U16 index)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- memset((S8*) hintData[(index)], 0, MAX_SUB_MENU_SIZE);
- switch (g_poc_cntx_p->contact_entry_disp.auth_rule.sub_handling)
- {
- case POC_MMI_SUB_BLOCK:
- pfnUnicodeStrcpy((S8*) hintData[index], (PS8) GetString(STR_ID_POC_REJECT));
- break;
- case POC_MMI_SUB_POLITE_BLOCK:
- pfnUnicodeStrcpy((S8*) hintData[index], (PS8) GetString(STR_ID_POC_POLITE_BLOCK));
- break;
- case POC_MMI_SUB_ALLOW:
- pfnUnicodeStrcpy((S8*) hintData[index], (PS8) GetString(STR_ID_POC_ACCEPT));
- break;
- default:
- pfnUnicodeStrcpy((S8*) hintData[index], (PS8) GetString(STR_GLOBAL_EMPTY));
- break;
- }
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_hint_subscribe_pres
- * DESCRIPTION
- * Hint handler of PoC menu
- * PARAMETERS
- * index [IN]
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_hint_subscribe_pres(U16 index)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- memset((S8*) hintData[(index)], 0, MAX_SUB_MENU_SIZE);
- switch (g_poc_cntx_p->contact_entry_disp.sub_pres)
- {
- case POC_SETTING_TRUE:
- pfnUnicodeStrcpy((S8*) hintData[index], (PS8) GetString(STR_GLOBAL_ON));
- break;
- default:
- pfnUnicodeStrcpy((S8*) hintData[index], (PS8) GetString(STR_GLOBAL_OFF));
- break;
- }
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_entry_contact
- * DESCRIPTION
- * poc contact screen
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_entry_contact(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- U8 *nStrItemList[POC_MAX_CONTACT_DISPLAY_NUM];
- U8 *guiBuffer;
- BOOL list_is_ready_p;
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- if (g_poc_cntx_p->progressing.contact == MMI_TRUE)
- {
- DisplayPopup(
- (U8*) GetString(STR_ID_POC_PROCESSING),
- IMG_GLOBAL_WARNING,
- 1,
- UI_POPUP_NOTIFYDURATION_TIME,
- (U8) WARNING_TONE);
- return;
- }
- mmi_poc_check_and_update_contact();
- EntryNewScreen(SCR_ID_POC_CONTACT, NULL, mmi_poc_entry_contact, NULL);
- guiBuffer = GetCurrGuiBuffer(SCR_ID_POC_CONTACT);
- RegisterHighlightHandler(mmi_poc_contact_highlight_handler);
- if (g_poc_cntx_p->contact_num == 0)
- {
- pfnUnicodeStrcpy((S8*) g_poc_cntx_p->contact_entry_disp.display_name, (PS8) GetString(STR_GLOBAL_EMPTY_LIST));
- nStrItemList[0] = g_poc_cntx_p->contact_entry_disp.display_name;
- ShowCategory6Screen(
- STR_ID_POC_CONTACTS,
- GetRootTitleIcon(MENU_ID_POC_MAIN),
- STR_GLOBAL_ADD,
- IMG_GLOBAL_OK,
- STR_GLOBAL_BACK,
- IMG_GLOBAL_BACK,
- 1,
- nStrItemList,
- NULL,
- 0,
- guiBuffer);
- SetLeftSoftkeyFunction(mmi_poc_entry_contact_opt_settings_add, KEY_EVENT_UP);
- }
- else
- {
- if (guiBuffer != NULL)
- {
- memset((void*)guiBuffer, 0, 2);
- if (g_poc_cntx_p->contact_selected >= g_poc_cntx_p->contact_num)
- {
- g_poc_cntx_p->contact_selected = g_poc_cntx_p->contact_num - 1;
- }
- }
- else
- {
- g_poc_cntx_p->contact_selected = 0;
- }
- ShowCategory425Screen(
- (UI_string_type) GetString(STR_ID_POC_CONTACTS),
- STR_GLOBAL_OPTIONS,
- IMG_GLOBAL_OPTIONS,
- STR_GLOBAL_BACK,
- IMG_GLOBAL_BACK,
- 0,
- 0,
- 0,
- g_poc_cntx_p->contact_num,
- mmi_poc_contact_get_items,
- mmi_poc_contact_get_hints,
- (PU8) GetImage(IMG_ID_POC_ONLINE),
- (PU8) GetImage(IMG_ID_POC_ONLINE),
- g_poc_cntx_p->contact_selected,
- guiBuffer,
- &list_is_ready_p);
- SetLeftSoftkeyFunction(mmi_poc_entry_contact_opt, KEY_EVENT_UP);
- SetKeyHandler(mmi_poc_entry_contact_opt, KEY_RIGHT_ARROW, KEY_EVENT_DOWN);
- }
- if (g_poc_cntx_p->contact_num > 0)
- {
- SetKeyHandler(mmi_poc_contact_1_to_1_invite, KEY_SEND, KEY_EVENT_DOWN);
- }
- SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP);
- SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_contact_get_items
- * DESCRIPTION
- * Fill items of contact list into UI buffers
- * PARAMETERS
- * start_index [IN] Start index of item to be retrieved
- * menu_data [IN] Address of menu data
- * data_size [IN] Maximal number of menu items can be put in the buffer
- * RETURNS
- * void
- *****************************************************************************/
- S32 mmi_poc_contact_get_items(S32 start_index, gui_iconlist_menu_item *menu_data, S32 data_size)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- S32 i, j;
- S32 count = (S32) g_poc_cntx_p->contact_num;
- mmi_poc_contact_list_disp *cont;
- gui_iconlist_menu_item *item = menu_data;
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- for (i = 0, j = (i + start_index); i < data_size && j < count; i++, j++)
- {
- cont = &g_poc_cntx_p->contact_list_disp[j];
- if (g_poc_cntx_p->contact_list[cont->group_id].entries[cont->entry_id].pres.is_active == MMI_TRUE)
- {
- item->image_list[0] = (PU8) GetImage(IMG_ID_POC_ONLINE);
- }
- else
- {
- item->image_list[0] = (PU8) GetImage(IMG_ID_POC_OFFLINE);
- }
- item->image_list[1] = NULL;
- if (g_poc_cntx_p->contact_list[cont->group_id].entries[cont->entry_id].allow_invite == POC_SETTING_FALSE)
- {
- item->image_list[2] = (PU8) GetImage(IMG_ID_POC_BLOCK);
- }
- else
- {
- item->image_list[2] = NULL;
- }
- mmi_poc_util_copy_with_dot(
- (S8*) g_poc_cntx_p->contact_list[cont->group_id].entries[cont->entry_id]. display_name,
- (S8*) item->item_list[0],
- MAX_SUBMENU_CHARACTERS - 1);
- mmi_poc_util_copy_with_dot(
- (S8*) g_poc_cntx_p->contact_list[cont->group_id].entries[cont->entry_id].uri,
- (S8*) item->item_list[1],
- MAX_SUBMENU_CHARACTERS - 1);
- item++;
- }
- return i;
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_contact_get_hints
- * DESCRIPTION
- * Fill items of hint list into UI buffers. Currently, it's no use.
- * PARAMETERS
- * start_index [IN] Start index of item to be retrieved
- * hint_array [IN] Buffer to strore list of hints
- * RETURNS
- * void
- *****************************************************************************/
- S32 mmi_poc_contact_get_hints(S32 start_index, UI_string_type *hint_array)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- return (0);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_util_copy_with_dot
- * DESCRIPTION
- * Append three dots to the end of string
- * PARAMETERS
- * source [IN] Source buffer.
- * dest [IN/OUT] Destination buffer.
- * max_len [IN] Max characters can be put in destination buffer , including NULL terminate
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_util_copy_with_dot(S8 *source, S8 *dest, S32 max_len)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- S8 *tmp_buff = OslMalloc((POC_MAX_URI_LEN + 1) * ENCODING_LENGTH);
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- AnsiiNToUnicodeString((S8*) tmp_buff, (S8*) source, POC_MAX_URI_LEN);
- if (pfnUnicodeStrlen(tmp_buff) <= max_len)
- {
- pfnUnicodeStrcpy((S8*) dest, (S8*) tmp_buff);
- }
- else
- {
- /* do not clear end of string because pfnUnicodeStrncpy will auto set NULL terminate */
- pfnUnicodeStrncpy((S8*) dest, (S8*) tmp_buff, max_len - 4);
- pfnUnicodeStrcat((S8*) dest, (S8*) g_poc_three_dot);
- }
- OslMfree(tmp_buff);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_sort_contact_by_name
- * DESCRIPTION
- * sort contact by display name
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_sort_contact_by_name(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- U8 i, j;
- mmi_poc_contact_list_disp *cont1;
- mmi_poc_contact_list_disp *cont2;
- mmi_poc_contact_list_disp temp_contact;
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- for (i = 0; i < g_poc_cntx_p->contact_num; i++)
- {
- cont1 = &g_poc_cntx_p->contact_list_disp[i];
- for (j = i + 1; j < g_poc_cntx_p->contact_num; j++)
- {
- cont2 = &g_poc_cntx_p->contact_list_disp[j];
- if (strcmp(
- (S8*) g_poc_cntx_p->contact_list[cont1->group_id].entries[cont1->entry_id].display_name,
- (S8*) g_poc_cntx_p->contact_list[cont2->group_id].entries[cont2->entry_id].display_name) > 0)
- {
- memcpy(&temp_contact, &g_poc_cntx_p->contact_list_disp[i], sizeof(mmi_poc_contact_list_disp));
- memcpy(
- &g_poc_cntx_p->contact_list_disp[i],
- &g_poc_cntx_p->contact_list_disp[j],
- sizeof(mmi_poc_contact_list_disp));
- memcpy(&g_poc_cntx_p->contact_list_disp[j], &temp_contact, sizeof(mmi_poc_contact_list_disp));
- }
- }
- }
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_check_and_update_contact
- * DESCRIPTION
- * check and update contact, including sort
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_check_and_update_contact(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- U8 i, j;
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- if (g_poc_cntx_p->contact_local_updated == MMI_FALSE)
- {
- g_poc_cntx_p->contact_num = 0;
- memset(g_poc_cntx_p->contact_list_disp, 0, sizeof(mmi_poc_contact_list_disp) * POC_MAX_CONTACT_DISPLAY_NUM);
- for (i = 0; i < MAX_POC_GROUP_FILE_NUM * MAX_POC_GROUPS_PER_FILE_NUM; i++)
- {
- if (g_poc_cntx_p->contact_list[i].valid == MMI_TRUE)
- {
- for (j = 0; j < g_poc_cntx_p->contact_list[i].no_entries; j++)
- {
- g_poc_cntx_p->contact_list_disp[g_poc_cntx_p->contact_num].group_id = i;
- g_poc_cntx_p->contact_list_disp[g_poc_cntx_p->contact_num].entry_id = j;
- g_poc_cntx_p->contact_num++;
- }
- }
- }
- mmi_poc_sort_contact_by_name();
- g_poc_cntx_p->contact_local_updated = MMI_TRUE;
- }
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_contact_highlight_handler
- * DESCRIPTION
- * poc contact highlight handler
- * PARAMETERS
- * index [IN] Current selected index
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_contact_highlight_handler(S32 index)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- g_poc_cntx_p->contact_selected = (U8) index;
- return;
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_entry_contact_opt
- * DESCRIPTION
- * contact option screen
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_entry_contact_opt(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- U16 nStrItemList[MAX_SUB_MENUS]; /* Stores the strings id of submenus returned */
- U16 nNumofItem; /* Stores no of children in the submenu */
- U8 *guiBuffer; /* Buffer holding history data */
- U16 menuId;
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- EntryNewScreen(SCR_ID_POC_CONTACT_OPT, NULL, mmi_poc_entry_contact_opt, NULL);
- guiBuffer = GetCurrGuiBuffer(SCR_ID_POC_CONTACT_OPT);
- menuId = MENU_ID_POC_CONTACT_OPT;
- nNumofItem = GetNumOfChild(menuId);
- GetSequenceStringIds(menuId, nStrItemList);
- SetParentHandler(menuId);
- RegisterHighlightHandler(ExecuteCurrHiliteHandler);
- ShowCategory15Screen(
- STR_GLOBAL_OPTIONS,
- GetRootTitleIcon(MENU_ID_POC_MAIN),
- STR_GLOBAL_OK,
- IMG_GLOBAL_OK,
- STR_GLOBAL_BACK,
- IMG_GLOBAL_BACK,
- nNumofItem,
- nStrItemList,
- (U16*) gIndexIconsImageList,
- 1,
- 0,
- guiBuffer);
- SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP);
- SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_entry_contact_opt_settings
- * DESCRIPTION
- * contact option setting screen
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_entry_contact_opt_settings(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- U16 nStrItemList[MAX_SUB_MENUS]; /* Stores the strings id of submenus returned */
- U16 nNumofItem; /* Stores no of children in the submenu */
- U8 *guiBuffer; /* Buffer holding history data */
- U16 menuId;
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- EntryNewScreen(SCR_ID_POC_CONTACT_ENTRY_SETTINGS, NULL, mmi_poc_entry_contact_opt_settings, NULL);
- guiBuffer = GetCurrGuiBuffer(SCR_ID_POC_CONTACT_ENTRY_SETTINGS);
- menuId = MENU_ID_POC_CONTACT_OPT_SETTINGS;
- nNumofItem = GetNumOfChild(menuId);
- GetSequenceStringIds(menuId, nStrItemList);
- SetParentHandler(menuId);
- RegisterHighlightHandler(ExecuteCurrHiliteHandler);
- ShowCategory15Screen(
- STR_ID_POC_ENTRY_SETTINGS,
- GetRootTitleIcon(MENU_ID_POC_MAIN),
- STR_GLOBAL_OK,
- IMG_GLOBAL_OK,
- STR_GLOBAL_BACK,
- IMG_GLOBAL_BACK,
- nNumofItem,
- nStrItemList,
- (U16*) gIndexIconsImageList,
- 1,
- 0,
- guiBuffer);
- SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP);
- SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_entry_contact_opt_settings_modify
- * DESCRIPTION
- * contact option settings modify screen
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_entry_contact_opt_settings_modify(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- U8 i, ImageLocation = 0;
- U8 *inputBuffer;
- U8 *guiBuffer;
- U16 inputBufferSize;
- U16 IconList[POC_CONTACT_INLINE_NUM];
- mmi_poc_contact_list_disp *cont;
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- EntryNewScreen(SCR_ID_POC_CONTACT_ENTRY_MODIFY, mmi_poc_exit_contact_opt_settings_modify, NULL, NULL);
- InitializeCategory57Screen();
- guiBuffer = GetCurrGuiBuffer(SCR_ID_POC_CONTACT_ENTRY_MODIFY);
- inputBuffer = GetCurrNInputBuffer(SCR_ID_POC_CONTACT_ENTRY_MODIFY, &inputBufferSize);
- SetParentHandler(MENU_ID_POC_CONTACT_OPT_SETTINGS_MODIFY);
- mmi_poc_contact_fill_inline_struct(XDM_PUT_REPLACE);
- if (inputBuffer != NULL)
- {
- SetCategory57Data(wgui_inline_items, POC_CONTACT_INLINE_NUM, inputBuffer);
- }
- else
- {
- cont = &g_poc_cntx_p->contact_list_disp[g_poc_cntx_p->contact_selected];
- g_poc_cntx_p->contact_entry_disp.allow_invite =
- g_poc_cntx_p->contact_list[cont->group_id].entries[cont->entry_id].allow_invite;
- g_poc_cntx_p->contact_entry_disp.sub_pres =
- g_poc_cntx_p->contact_list[cont->group_id].entries[cont->entry_id].sub_pres;
- memcpy(
- &g_poc_cntx_p->contact_entry_disp.auth_rule,
- &g_poc_cntx_p->contact_list[cont->group_id].entries[cont->entry_id].auth_rule,
- sizeof(poc_pres_authrule_struct));
- if (strlen((S8*) g_poc_cntx_p->contact_list[cont->group_id].entries[cont->entry_id].uri))
- {
- AnsiiNToUnicodeString(
- (S8*) g_poc_cntx_p->contact_entry_disp.uri,
- (S8*) g_poc_cntx_p->contact_list[cont->group_id].entries[cont->entry_id].uri,
- POC_MAX_URI_LEN - 1);
- }
- else
- {
- AnsiiNToUnicodeString(
- (S8*) g_poc_cntx_p->contact_entry_disp.uri,
- (S8*) POC_MMI_SIP_PREFIX,
- POC_MAX_URI_LEN - 1);
- }
- AnsiiNToUnicodeString(
- (S8*) g_poc_cntx_p->contact_entry_disp.display_name,
- (S8*) g_poc_cntx_p->contact_list[cont->group_id].entries[cont->entry_id].display_name,
- POC_MAX_DISP_LEN - 1);
- memcpy(
- &g_poc_cntx_p->contact_entry_disp.pres,
- &g_poc_cntx_p->contact_list[cont->group_id].entries[cont->entry_id].pres,
- sizeof(mmi_poc_presence_struct));
- }
- if (guiBuffer == 0)
- {
- g_poc_cntx_p->inline_item_changed = MMI_FALSE;
- }
- if ((get_wgui_inline_list_menu_status() || g_poc_cntx_p->inline_item_changed) &&
- (GetInlineDoneFlag(guiBuffer) == 0))
- {
- SetInlineDoneFlag(guiBuffer);
- }
- for (i = 0; i < POC_CONTACT_INLINE_NUM; i++)
- {
- if (i % 2)
- {
- IconList[i] = IMG_ID_POC_NOIMAGE;
- }
- else
- {
- IconList[i] = IMG_ID_POC_CONTACT_NAME + ImageLocation;
- ImageLocation++;
- }
- }
- ShowCategory57Screen(
- STR_ID_POC_ENTRY_INFO,
- GetRootTitleIcon(MENU_ID_POC_MAIN),
- STR_GLOBAL_EDIT,
- IMG_GLOBAL_OK,
- STR_GLOBAL_BACK,
- IMG_GLOBAL_BACK,
- POC_CONTACT_INLINE_NUM,
- IconList,
- wgui_inline_items,
- 0,
- guiBuffer);
- SetCategory57RightSoftkeyFunctions(mmi_poc_entry_contact_opt_settings_modify_cfrm, GoBackHistory);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_exit_contact_opt_settings_modify
- * DESCRIPTION
- * modify exit screen
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_exit_contact_opt_settings_modify(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- set_leading_zero(TRUE);
- GenericExitInlineScreen(SCR_ID_POC_CONTACT_ENTRY_MODIFY, mmi_poc_entry_contact_opt_settings_modify);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_contact_fill_inline_struct
- * DESCRIPTION
- * fill inline editor structure
- * PARAMETERS
- * op [IN] XDM_PUT_ADD or XDM_PUT_REPLACE
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_contact_fill_inline_struct(U8 op)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- S32 BufferSize = 0;
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- SetInlineItemActivation((wgui_inline_items + POC_CONTACT_NAME), KEY_LSK, KEY_EVENT_UP);
- SetInlineItemActivation((wgui_inline_items + POC_CONTACT_URI), KEY_LSK, KEY_EVENT_UP);
- SetInlineItemActivation((wgui_inline_items + POC_CONTACT_ATTR), KEY_LSK, KEY_EVENT_UP);
- SetInlineItemCaption((wgui_inline_items + POC_CONTACT_NAME_STR), (U8*) GetString(STR_ID_POC_NAME));
- SetInlineItemCaption((wgui_inline_items + POC_CONTACT_URI_STR), (U8*) GetString(STR_ID_POC_URI));
- SetInlineItemCaption((wgui_inline_items + POC_CONTACT_ATTR_STR), (U8*) GetString(STR_ID_POC_ATTRIBUTES));
- BufferSize = POC_MAX_DISP_LEN - 1;
- SetInlineItemFullScreenEdit_ext(
- (wgui_inline_items + POC_CONTACT_NAME),
- STR_ID_POC_NAME,
- GetRootTitleIcon(MENU_ID_POC_MAIN),
- (U8*) (g_poc_cntx_p->contact_entry_disp.display_name),
- BufferSize,
- (INPUT_TYPE_ALPHANUMERIC_SENTENCECASE | INPUT_TYPE_USE_ONLY_ENGLISH_MODES),
- INPUT_TYPE_EXT_NO_SHOW_NEW_LINE_SYMBOL);
- SetInlineFullScreenEditCustomFunction(wgui_inline_items + POC_CONTACT_NAME, mmi_poc_entry_full_line_edit);
- if (op == XDM_PUT_ADD)
- {
- BufferSize = POC_MAX_URI_LEN - 1;
- SetInlineItemFullScreenEdit_ext(
- (wgui_inline_items + POC_CONTACT_URI),
- STR_ID_POC_URI,
- GetRootTitleIcon(MENU_ID_POC_MAIN),
- (U8*) (g_poc_cntx_p->contact_entry_disp.uri),
- BufferSize,
- (INPUT_TYPE_ALPHANUMERIC_SENTENCECASE | INPUT_TYPE_USE_ONLY_ENGLISH_MODES),
- INPUT_TYPE_EXT_NO_SHOW_NEW_LINE_SYMBOL);
- SetInlineFullScreenEditCustomFunction(wgui_inline_items + POC_CONTACT_URI, mmi_poc_entry_full_line_edit);
- }
- else
- {
- SetInlineItemDisplayOnly(
- (wgui_inline_items + POC_TALK_GROUP_URI),
- (U8*) (g_poc_cntx_p->contact_entry_disp.uri));
- }
- SetInlineItemImageText(
- (wgui_inline_items + POC_CONTACT_ATTR),
- (U8*) GetString(STR_ID_POC_SET_ATTR),
- (PU8) NULL,
- NULL,
- NULL,
- POC_MAX_DISP_LEN,
- 0,
- 0,
- INPUT_TYPE_ALPHANUMERIC_SENTENCECASE);
- SetInlineFullScreenEditCustomFunctionImageText(
- (wgui_inline_items + POC_CONTACT_ATTR),
- mmi_poc_entry_contact_opt_settings_attributes);
- ShowAsControl(wgui_inline_items + POC_CONTACT_ATTR);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_entry_contact_opt_settings_add
- * DESCRIPTION
- * settings add screen
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_entry_contact_opt_settings_add(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- U8 i, ImageLocation = 0;
- U8 *inputBuffer;
- U8 *guiBuffer;
- U16 inputBufferSize;
- U16 IconList[POC_CONTACT_INLINE_NUM];
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- if (g_poc_cntx_p->contact_num >= POC_GROUP_LOCAL_MAX_ENTRIES_NUM)
- {
- DisplayPopup(
- (U8*) GetString(STR_ID_POC_ERR_MAXIMUM_REACHED),
- IMG_GLOBAL_UNFINISHED,
- 1,
- UI_POPUP_NOTIFYDURATION_TIME,
- (U8) ERROR_TONE);
- return;
- }
- EntryNewScreen(SCR_ID_POC_CONTACT_ENTRY_ADD, mmi_poc_exit_contact_opt_settings_add, NULL, NULL);
- InitializeCategory57Screen();
- guiBuffer = GetCurrGuiBuffer(SCR_ID_POC_CONTACT_ENTRY_ADD);
- inputBuffer = GetCurrNInputBuffer(SCR_ID_POC_CONTACT_ENTRY_ADD, &inputBufferSize);
- SetParentHandler(MENU_ID_POC_CONTACT_OPT_SETTINGS_ADD);
- mmi_poc_contact_fill_inline_struct(XDM_PUT_ADD);
- if (inputBuffer != NULL)
- {
- SetCategory57Data(wgui_inline_items, POC_CONTACT_INLINE_NUM, inputBuffer);
- }
- else
- {
- memset(&g_poc_cntx_p->contact_entry_disp, 0, sizeof(mmi_poc_contact_entry_disp_struct));
- #ifdef __MMI_POC_ETS_TESTCODE__
- AnsiiNToUnicodeString(
- (S8*) g_poc_cntx_p->contact_entry_disp.uri,
- (S8*) "sip:PocUser1E@ims3.vfd2-testnetz.de",
- POC_MAX_URI_LEN - 1);
- #else /* __MMI_POC_ETS_TESTCODE__ */
- AnsiiNToUnicodeString(
- (S8*) g_poc_cntx_p->contact_entry_disp.uri,
- (S8*) POC_MMI_SIP_PREFIX,
- POC_MAX_URI_LEN - 1);
- #endif /* __MMI_POC_ETS_TESTCODE__ */
- g_poc_cntx_p->contact_entry_disp.allow_invite = POC_SETTING_TRUE;
- g_poc_cntx_p->contact_entry_disp.sub_pres = POC_SETTING_TRUE;
- g_poc_cntx_p->contact_entry_disp.auth_rule.sub_handling = POC_MMI_SUB_ALLOW;
- g_poc_cntx_p->contact_entry_disp.auth_rule.pres_attr = POC_PRES_PROVIDE_ALL;
- }
- if (guiBuffer == 0)
- {
- g_poc_cntx_p->inline_item_changed = MMI_FALSE;
- }
- if ((get_wgui_inline_list_menu_status() || g_poc_cntx_p->inline_item_changed) &&
- (GetInlineDoneFlag(guiBuffer) == 0))
- {
- SetInlineDoneFlag(guiBuffer);
- }
- for (i = 0; i < POC_CONTACT_INLINE_NUM; i++)
- {
- if (i % 2)
- {
- IconList[i] = IMG_ID_POC_NOIMAGE;
- }
- else
- {
- IconList[i] = IMG_ID_POC_CONTACT_NAME + ImageLocation;
- ImageLocation++;
- }
- }
- ShowCategory57Screen(
- STR_ID_POC_ENTRY_INFO,
- GetRootTitleIcon(MENU_ID_POC_MAIN),
- STR_GLOBAL_EDIT,
- IMG_GLOBAL_OK,
- STR_GLOBAL_BACK,
- IMG_GLOBAL_BACK,
- POC_CONTACT_INLINE_NUM,
- IconList,
- wgui_inline_items,
- 0,
- guiBuffer);
- SetCategory57RightSoftkeyFunctions(mmi_poc_entry_contact_opt_settings_add_cfrm, GoBackHistory);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_exit_contact_opt_settings_add
- * DESCRIPTION
- * settings add screen exit function
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_exit_contact_opt_settings_add(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- set_leading_zero(TRUE);
- GenericExitInlineScreen(SCR_ID_POC_CONTACT_ENTRY_ADD, mmi_poc_entry_contact_opt_settings_add);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_entry_contact_opt_settings_attributes
- * DESCRIPTION
- * settings attribute screen
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_entry_contact_opt_settings_attributes(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- U16 nStrItemList[MAX_SUB_MENUS]; /* Stores the strings id of submenus returned */
- U16 nNumofItem; /* Stores no of children in the submenu */
- U8 *guiBuffer; /* Buffer holding history data */
- U16 menuId;
- U8 *PoCHint[MAX_SUB_MENUS];
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- EntryNewScreen(SCR_ID_POC_CONTACT_ENTRY_ATTR, NULL, mmi_poc_entry_contact_opt_settings_attributes, NULL);
- guiBuffer = GetCurrGuiBuffer(SCR_ID_POC_CONTACT_ENTRY_ATTR);
- menuId = MENU_ID_POC_CONTACT_OPT_SETTINGS_ATTRIBUTES;
- nNumofItem = GetNumOfChild(menuId);
- GetSequenceStringIds(menuId, nStrItemList);
- SetParentHandler(menuId);
- ConstructHintsList(menuId, PoCHint);
- RegisterHighlightHandler(ExecuteCurrHiliteHandler);
- ShowCategory52Screen(
- STR_ID_POC_ATTRIBUTES,
- GetRootTitleIcon(MENU_ID_POC_MAIN),
- STR_GLOBAL_OK,
- IMG_GLOBAL_OK,
- STR_GLOBAL_BACK,
- IMG_GLOBAL_BACK,
- nNumofItem,
- nStrItemList,
- (U16*) gIndexIconsImageList,
- PoCHint,
- 0,
- 0,
- guiBuffer);
- SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP);
- SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_go_back_contact_list
- * DESCRIPTION
- * go back contact list
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_go_back_contact_list(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- stopRequestedTone(WARNING_TONE);
- DeleteUptoScrID(SCR_ID_POC_CONTACT);
- GoBackHistory();
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_entry_contact_opt_settings_attributes_allow_invite
- * DESCRIPTION
- * allow invite screen
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_entry_contact_opt_settings_attributes_allow_invite(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- U16 nStrItemList[MAX_SUB_MENUS]; /* Stores the strings id of submenus returned */
- U16 nNumofItem; /* Stores no of children in the submenu */
- U8 *guiBuffer; /* Buffer holding history data */
- U16 menuId;
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- EntryNewScreen(
- SCR_ID_POC_CONTACT_ENTRY_ALLOW_INVITE,
- NULL,
- mmi_poc_entry_contact_opt_settings_attributes_allow_invite,
- NULL);
- guiBuffer = GetCurrGuiBuffer(SCR_ID_POC_CONTACT_ENTRY_ALLOW_INVITE);
- menuId = MENU_ID_POC_CONTACT_OPT_SETTINGS_ATTRIBUTES_ALLOW_INVITE;
- nNumofItem = GetNumOfChild(menuId);
- GetSequenceStringIds(menuId, nStrItemList);
- SetParentHandler(menuId);
- RegisterHighlightHandler(ExecuteCurrHiliteHandler);
- ShowCategory15Screen(
- STR_ID_POC_ALLOW_INVITE,
- GetRootTitleIcon(MENU_ID_POC_MAIN),
- STR_GLOBAL_OK,
- IMG_GLOBAL_OK,
- STR_GLOBAL_BACK,
- IMG_GLOBAL_BACK,
- nNumofItem,
- nStrItemList,
- (U16*) gIndexIconsImageList,
- 1,
- 0,
- guiBuffer);
- SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP);
- SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_contact_set_allow_invite_accept
- * DESCRIPTION
- * set allow invite option
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_contact_set_allow_invite_accept(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- g_poc_cntx_p->contact_entry_disp.allow_invite = POC_SETTING_TRUE;
- g_poc_cntx_p->inline_item_changed = MMI_TRUE;
- GoBackHistory();
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_contact_set_allow_invite_auto
- * DESCRIPTION
- * set allow invite option
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_contact_set_allow_invite_auto(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- g_poc_cntx_p->contact_entry_disp.allow_invite = POC_SETTING_ACCEPT;
- g_poc_cntx_p->inline_item_changed = MMI_TRUE;
- GoBackHistory();
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_contact_set_allow_invite_reject
- * DESCRIPTION
- * set allow invite option
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_contact_set_allow_invite_reject(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- g_poc_cntx_p->contact_entry_disp.allow_invite = POC_SETTING_FALSE;
- g_poc_cntx_p->inline_item_changed = MMI_TRUE;
- GoBackHistory();
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_entry_allow_subscribe
- * DESCRIPTION
- * allow subscribe screen
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_entry_allow_subscribe(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- U16 nStrItemList[MAX_SUB_MENUS]; /* Stores the strings id of submenus returned */
- U16 nNumofItem; /* Stores no of children in the submenu */
- U8 *guiBuffer; /* Buffer holding history data */
- U16 menuId;
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- EntryNewScreen(SCR_ID_POC_CONTACT_ENTRY_ALLOW_SUBSCRIBE, NULL, mmi_poc_entry_allow_subscribe, NULL);
- guiBuffer = GetCurrGuiBuffer(SCR_ID_POC_CONTACT_ENTRY_ALLOW_SUBSCRIBE);
- menuId = MENU_ID_POC_CONTACT_OPT_SETTINGS_ATTRIBUTES_ALLOW_SUBSCRIBE;
- nNumofItem = GetNumOfChild(menuId);
- GetSequenceStringIds(menuId, nStrItemList);
- SetParentHandler(menuId);
- RegisterHighlightHandler(ExecuteCurrHiliteHandler);
- ShowCategory15Screen(
- STR_ID_POC_ALLOW_SUBSCRIBE,
- GetRootTitleIcon(MENU_ID_POC_MAIN),
- STR_GLOBAL_OK,
- IMG_GLOBAL_OK,
- STR_GLOBAL_BACK,
- IMG_GLOBAL_BACK,
- nNumofItem,
- nStrItemList,
- (U16*) gIndexIconsImageList,
- 1,
- 0,
- guiBuffer);
- SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP);
- SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_entry_allow_subscribe_block
- * DESCRIPTION
- * allow subscribe block
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_entry_allow_subscribe_block(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- g_poc_cntx_p->contact_entry_disp.auth_rule.sub_handling = POC_MMI_SUB_BLOCK;
- g_poc_cntx_p->inline_item_changed = MMI_TRUE;
- GoBackHistory();
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_entry_allow_subscribe_polite_block
- * DESCRIPTION
- * allow subscribe polite block
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_entry_allow_subscribe_polite_block(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- g_poc_cntx_p->contact_entry_disp.auth_rule.sub_handling = POC_MMI_SUB_POLITE_BLOCK;
- g_poc_cntx_p->inline_item_changed = MMI_TRUE;
- GoBackHistory();
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_entry_allow_subscribe_allow
- * DESCRIPTION
- * allow subscribe, allow
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_entry_allow_subscribe_allow(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- g_poc_cntx_p->contact_entry_disp.auth_rule.sub_handling = POC_MMI_SUB_ALLOW;
- g_poc_cntx_p->inline_item_changed = MMI_TRUE;
- GoBackHistory();
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_contact_set_subscribe_pres
- * DESCRIPTION
- * set subscribe presence
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_contact_set_subscribe_pres(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- switch (g_poc_cntx_p->contact_entry_disp.sub_pres)
- {
- case POC_SETTING_TRUE:
- g_poc_cntx_p->contact_entry_disp.sub_pres = POC_SETTING_FALSE;
- break;
- default:
- g_poc_cntx_p->contact_entry_disp.sub_pres = POC_SETTING_TRUE;
- break;
- }
- DisplayPopup(
- (U8*) GetString(STR_GLOBAL_DONE),
- IMG_GLOBAL_ACTIVATED,
- 1,
- UI_POPUP_NOTIFYDURATION_TIME,
- (U8) SUCCESS_TONE);
- g_poc_cntx_p->inline_item_changed = MMI_TRUE;
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_entry_contact_opt_settings_attributes_provide_pres
- * DESCRIPTION
- * provide presence screen
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_entry_contact_opt_settings_attributes_provide_pres(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- U16 nStrItemList[MAX_SUB_MENUS];
- U16 nNumofItem;
- U8 i = 0;
- U8 *guiBuffer;
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- EntryNewScreen(
- SCR_ID_POC_CONTACT_ENTRY_PRES_ATTR,
- NULL,
- mmi_poc_entry_contact_opt_settings_attributes_provide_pres,
- NULL);
- guiBuffer = GetCurrGuiBuffer(SCR_ID_POC_CONTACT_ENTRY_PRES_ATTR);
- nNumofItem = GetNumOfChild(MENU_ID_POC_CONTACT_OPT_SETTINGS_ATTRIBUTES_PROVIDE_PRES);
- GetSequenceStringIds(MENU_ID_POC_CONTACT_OPT_SETTINGS_ATTRIBUTES_PROVIDE_PRES, nStrItemList);
- for (i = 0; i < nNumofItem; i++)
- {
- subMenuDataPtrs[i] = subMenuData[i];
- memset((S8*) subMenuDataPtrs[i], 0, MAX_SUB_MENU_SIZE);
- pfnUnicodeStrncpy((S8*) subMenuDataPtrs[i], GetString(nStrItemList[i]), MAX_SUBMENU_CHARACTERS - 1);
- }
- SetParentHandler(MENU_ID_POC_CONTACT_OPT_SETTINGS_ATTRIBUTES_PROVIDE_PRES);
- if (guiBuffer == NULL)
- {
- memset(g_poc_cntx_p->pres_attr_disp, 0, sizeof(U8) * POC_PRES_TOTAL_NUM);
- if (g_poc_cntx_p->contact_entry_disp.auth_rule.pres_attr & POC_PRES_PROVIDE_ACTIVITY)
- {
- g_poc_cntx_p->pres_attr_disp[POC_PRES_ACTIVITY] = MMI_TRUE;
- }
- if (g_poc_cntx_p->contact_entry_disp.auth_rule.pres_attr & POC_PRES_PROVIDE_MOOD)
- {
- g_poc_cntx_p->pres_attr_disp[POC_PRES_MOOD] = MMI_TRUE;
- }
- if (g_poc_cntx_p->contact_entry_disp.auth_rule.pres_attr == POC_PRES_PROVIDE_ALL)
- {
- g_poc_cntx_p->pres_attr_disp[POC_PRES_ALL] = MMI_TRUE;
- }
- }
- SetCheckboxToggleRightSoftkeyFunctions(mmi_poc_contact_set_pres_attr_cfrm, GoBackHistory);
- ShowCategory140Screen(
- STR_ID_POC_PRESENCE_ATTR,
- GetRootTitleIcon(MENU_ID_POC_MAIN),
- nNumofItem,
- (U8 **) subMenuDataPtrs,
- g_poc_cntx_p->pres_attr_disp,
- 0,
- guiBuffer);
- SetKeyHandler(GoBackHistory, KEY_LEFT_ARROW, KEY_EVENT_DOWN);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_contact_set_pres_attr_cfrm
- * DESCRIPTION
- * set presence attribute confirm
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_contact_set_pres_attr_cfrm(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- DisplayConfirm(
- STR_GLOBAL_YES,
- IMG_GLOBAL_YES,
- STR_GLOBAL_NO,
- IMG_GLOBAL_NO,
- get_string(STR_GLOBAL_SAVE),
- IMG_GLOBAL_QUESTION,
- WARNING_TONE);
- SetLeftSoftkeyFunction(mmi_poc_contact_set_pres_attr, KEY_EVENT_UP);
- SetRightSoftkeyFunction(poc_go_back_entry_attr, KEY_EVENT_UP);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_contact_set_pres_attr
- * DESCRIPTION
- * set presence attribute
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_contact_set_pres_attr(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- g_poc_cntx_p->contact_entry_disp.auth_rule.pres_attr = 0;
- if (g_poc_cntx_p->pres_attr_disp[POC_PRES_ACTIVITY] == MMI_TRUE)
- {
- g_poc_cntx_p->contact_entry_disp.auth_rule.pres_attr |= POC_PRES_PROVIDE_ACTIVITY;
- }
- if (g_poc_cntx_p->pres_attr_disp[POC_PRES_MOOD] == MMI_TRUE)
- {
- g_poc_cntx_p->contact_entry_disp.auth_rule.pres_attr |= POC_PRES_PROVIDE_MOOD;
- }
- if (g_poc_cntx_p->pres_attr_disp[POC_PRES_ALL] == MMI_TRUE)
- {
- g_poc_cntx_p->contact_entry_disp.auth_rule.pres_attr |= POC_PRES_PROVIDE_ALL;
- }
- g_poc_cntx_p->inline_item_changed = MMI_TRUE;
- DisplayPopup((PU8) GetString(STR_GLOBAL_DONE), IMG_GLOBAL_ACTIVATED, 1, UI_POPUP_NOTIFYDURATION_TIME, SUCCESS_TONE);
- DeleteScreenIfPresent(SCR_ID_POC_CONTACT_ENTRY_PRES_ATTR);
- }
- /*****************************************************************************
- * FUNCTION
- * poc_go_back_entry_attr
- * DESCRIPTION
- * go back to entry screen
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void poc_go_back_entry_attr(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- stopRequestedTone(WARNING_TONE);
- DeleteScreenIfPresent(SCR_ID_POC_CONTACT_ENTRY_PRES_ATTR);
- GoBackHistory();
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_entry_contact_opt_settings_modify_cfrm
- * DESCRIPTION
- * settings modify confirm screen
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_entry_contact_opt_settings_modify_cfrm(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- DisplayConfirm(
- STR_GLOBAL_YES,
- IMG_GLOBAL_YES,
- STR_GLOBAL_NO,
- IMG_GLOBAL_NO,
- get_string(STR_GLOBAL_SAVE),
- IMG_GLOBAL_QUESTION,
- WARNING_TONE);
- SetLeftSoftkeyFunction(mmi_poc_contact_send_modify, KEY_EVENT_UP);
- SetRightSoftkeyFunction(mmi_poc_go_back_contact_list, KEY_EVENT_UP);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_contact_send_modify
- * DESCRIPTION
- * send settings modify
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_contact_send_modify(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- g_poc_cntx_p->curr_contact_op = XDM_PUT_REPLACE;
- mmi_poc_update_group_entry_req(XDM_PUT_REPLACE);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_entry_contact_opt_settings_add_cfrm
- * DESCRIPTION
- * add confirm screen
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_entry_contact_opt_settings_add_cfrm(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- DisplayConfirm(
- STR_GLOBAL_YES,
- IMG_GLOBAL_YES,
- STR_GLOBAL_NO,
- IMG_GLOBAL_NO,
- get_string(STR_GLOBAL_SAVE),
- IMG_GLOBAL_QUESTION,
- WARNING_TONE);
- SetLeftSoftkeyFunction(mmi_poc_contact_send_add, KEY_EVENT_UP);
- SetRightSoftkeyFunction(mmi_poc_go_back_contact_list, KEY_EVENT_UP);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_contact_send_add
- * DESCRIPTION
- * send contact add
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_contact_send_add(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- #ifdef __MMI_POC_ALWAYS_CREATE_MTK_CONTACT__
- U8 i, j;
- #endif
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- if ((g_poc_cntx_p->contact_num > 0) ||
- ((g_poc_cntx_p->contact_list[0].valid == MMI_TRUE) &&
- (g_poc_cntx_p->contact_list[0].list_name[0] != 0)))
- {
- #ifdef __MMI_POC_ALWAYS_CREATE_MTK_CONTACT__
- for (i = 0; i < MAX_POC_GROUP_FILE_NUM * MAX_POC_GROUPS_PER_FILE_NUM; i++)
- {
- if (!strncmp
- ((S8*) g_poc_cntx_p->contact_list[i].list_name, (S8*) POC_MTK_DEFAULT_CONTACT,
- sizeof(POC_MTK_DEFAULT_CONTACT)))
- {
- break;
- }
- }
- if (i == MAX_POC_GROUP_FILE_NUM * MAX_POC_GROUPS_PER_FILE_NUM)
- {
- /* mtk contact not found */
- mmi_poc_create_group_list_req();
- }
- else
- {
- g_poc_cntx_p->curr_contact_op = XDM_PUT_ADD;
- mmi_poc_update_group_entry_req(XDM_PUT_ADD);
- }
- #else /* __MMI_POC_ALWAYS_CREATE_MTK_CONTACT__ */
- g_poc_cntx_p->curr_contact_op = XDM_PUT_ADD;
- mmi_poc_update_group_entry_req(XDM_PUT_ADD);
- #endif /* __MMI_POC_ALWAYS_CREATE_MTK_CONTACT__ */
- }
- else
- {
- memset(g_poc_cntx_p->contact_list, 0, sizeof(g_poc_cntx_p->contact_list));
- mmi_poc_create_group_list_req();
- }
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_entry_progressing
- * DESCRIPTION
- * entry progressing screen
- * PARAMETERS
- * void
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_entry_progressing(void)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- U8 *guiBuffer;
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- EntryNewScreen(SCR_ID_POC_GENERAL_PROGRESSING, NULL, mmi_poc_entry_progressing, NULL);
- DeleteScreenIfPresent(SCR_ID_POC_GENERAL_PROGRESSING);
- guiBuffer = GetCurrGuiBuffer(SCR_ID_POC_GENERAL_PROGRESSING);
- ShowCategory66Screen(
- STR_ID_POC_MAIN,
- GetRootTitleIcon(MENU_ID_POC_MAIN),
- 0,
- 0,
- STR_GLOBAL_BACK,
- IMG_GLOBAL_BACK,
- (U8*) GetString(STR_ID_POC_PROCESSING),
- IMG_GLOBAL_PROGRESS,
- NULL);
- SetRightSoftkeyFunction(GoBackHistory, KEY_EVENT_UP);
- }
- /*****************************************************************************
- * FUNCTION
- * mmi_poc_update_group_entry_req
- * DESCRIPTION
- * update group entry request
- * PARAMETERS
- * op [IN]
- * RETURNS
- * void
- *****************************************************************************/
- void mmi_poc_update_group_entry_req(U8 op)
- {
- /*----------------------------------------------------------------*/
- /* Local Variables */
- /*----------------------------------------------------------------*/
- MYQUEUE Message;
- mmi_poc_contact_list_disp *cont;
- poc_update_group_entry_req_struct *myMsgPtr;
- U8 i, new_idx;
- /*----------------------------------------------------------------*/
- /* Code Body */
- /*----------------------------------------------------------------*/
- if (g_poc_cntx_p->curr_use_xdm_mode == MMI_TRUE)
- {
- myMsgPtr = (poc_update_group_entry_req_struct*) OslConstructDataPtr(sizeof(poc_update_group_entry_req_struct));
- memset(
- (U8*) myMsgPtr + sizeof(mmi_poc_dummy_req_struct),
- 0,
- sizeof(poc_update_group_entry_req_struct) - sizeof(mmi_poc_dummy_req_struct));
- myMsgPtr->request_id = POC_REQUEST_ID;
- myMsgPtr->op = op;
- cont = &g_poc_cntx_p->contact_list_disp[g_poc_cntx_p->contact_selected];
- myMsgPtr->entry.allow_invite = g_poc_cntx_p->contact_entry_disp.allow_invite;
- myMsgPtr->entry.sub_pres = g_poc_cntx_p->contact_entry_disp.sub_pres;
- memcpy(
- &myMsgPtr->entry.auth_rule,
- &g_poc_cntx_p->contact_entry_disp.auth_rule,
- sizeof(poc_pres_authrule_struct));
- UnicodeNToAnsii((S8*) myMsgPtr->entry.uri, (S8*) g_poc_cntx_p->contact_entry_disp.uri, POC_MAX_URI_LEN - 1);
- UnicodeNToAnsii(
- (S8*) myMsgPtr->entry.disp_name,
- (S8*) g_poc_cntx_p->contact_entry_disp.display_name,
- POC_MAX_DISP_LEN - 1);
- if (myMsgPtr->entry.uri[0] == 0 || !strstr((S8*) myMsgPtr->entry.uri, (S8*) "@"))
- {
- DisplayPopup(
- (PU8) GetString(STR_ID_POC_NULL_STR_ERR),
- IMG_GLOBAL_UNFINISHED,
- 1,
- CS_NOTIFYDURATION,
- ERROR_TONE);
- return;
- }
- myMsgPtr->entry.xdm_item = 0;
- g_poc_cntx_p->session_xdm = 0;
- if (op == XDM_PUT_ADD)
- {
- #ifdef __MMI_POC_ALWAYS_CREATE_MTK_CONTACT__
- myMsgPtr->entry.xdm_item = 0x0F;
- strncpy(
- (char*)myMsgPtr->list_name,
- (char*)g_poc_cntx_p->contact_list[cont->group_id].list_name,
- POC_MAX_DISP_LEN - 1);
- #else /* __MMI_POC_ALWAYS_CREATE_MTK_CONTACT__ */
- U8 least_num = POC_GROUP_LOCAL_MAX_ENTRIES_NUM;
- myMsgPtr->entry.xdm_item = 0x0F;
- g_poc_cntx_p->update_grp_idx = 0;
- for (i = 0; i < MAX_POC_GROUP_FILE_NUM * MAX_POC_GROUPS_PER_FILE_NUM; i++)
- {
- if ((g_poc_cntx_p->contact_list[i].valid == MMI_TRUE) &&
- (g_poc_cntx_p->contact_list[i].no_entries < least_num))
- {
- least_num = g_poc_cntx_p->contact_list[i].no_entries;
- g_poc_cntx_p->update_grp_idx = i;
- }
- }
- strncpy(
- (char*)myMsgPtr->list_name,
- (char*)g_poc_cntx_p->contact_list[g_poc_cntx_p->update_grp_idx].list_name,
- POC_MAX_DISP_LEN - 1);
- #endif /* __MMI_POC_ALWAYS_CREATE_MTK_CONTACT__ */
- }
- else
- {
- strncpy(
- (char*)myMsgPtr->list_name,
- (char*)g_poc_cntx_p->contact_list[cont->group_id].list_name,
- POC_MAX_DISP_LEN - 1);
- if (strncmp
- ((S8*) myMsgPtr->entry.uri,
- (S8*) g_poc_cntx_p->contact_list[cont->group_id].entries[cont->entry_id].uri, POC_MAX_URI_LEN - 1) ||
- strncmp(
- (S8*) myMsgPtr->entry.disp_name,
- (S8*) g_poc_cntx_p->contact_list[cont->group_id].entries[cont->entry_id].display_name,
- POC_MAX_DISP_LEN - 1))
- {
- myMsgPtr->entry.xdm_item |= POC_XDM_GL_PRESENT;
- }
- if (myMsgPtr->entry.allow_invite !=
- g_poc_cntx_p->contact_list[cont->group_id].entries[cont->entry_id].allow_invite)
- {
- myMsgPtr->entry.xdm_item |= POC_XDM_AL_PRESENT;
- }
- if (myMsgPtr->entry.auth_rule.pres_attr !=
- g_poc_cntx_p->contact_list[cont->group_id].entries[cont->entry_id].auth_rule.pres_attr ||
- myMsgPtr->entry.auth_rule.sub_handling !=
- g_poc_cntx_p->contact_list[cont->group_id].entries[cont->entry_id].auth_rule.sub_handling)
- {
- if (g_poc_cntx_p->contact_entry_disp.auth_rule.sub_handling != POC_MMI_SUB_EMPTY)
- {
- myMsgPtr->entry.auth_rule.sub_handling =
- g_poc_cntx_p->contact_entry_disp.auth_rule.sub_handling - 1;
- }
- myMsgPtr->entry.xdm_item |= POC_XDM_AR_PRESENT;
- }
- if (myMsgPtr->entry.sub_pres != g_poc_cntx_p->contact_list[cont->group_id].entries[cont->entry_id].sub_pres)
- {
- myMsgPtr->entry.xdm_item |= POC_XDM_RLS_PRESENT;
- }
- }
- g_poc_cntx_p->session_xdm = myMsgPtr->entry.xdm_item;
- SetProtocolEventHandler(mmi_poc_update_group_entry_rsp, MSG_ID_POC_UPDATE_GROUP_ENTRY_RSP);
- g_poc_cntx_p->progressing.contact = MMI_TRUE;
- mmi_poc_entry_progressing();
- DeleteUptoScrID(SCR_ID_POC_CONTACT);
- DeleteScreenIfPresent(SCR_ID_POC_CONTACT);
- Message.oslSrcId = MOD_MMI;
- Message.oslDestId = MOD_POC;
- Message.oslMsgId = MSG_ID_POC_UPDATE_GROUP_ENTRY_REQ;
- Message.oslDataPtr = (oslParaType*) myMsgPtr;
- Message.oslPeerBuffPtr = NULL;
- OslMsgSendExtQueue(&Message);
- }
- else
- {
- kal_uint8 temp_uri[POC_MAX_URI_LEN];
- memset((S8*) temp_uri, 0, sizeof(temp_uri));
- UnicodeNToAnsii((S8*) temp_uri, (S8*) g_poc_cntx_p->contact_entry_disp.uri, POC_MAX_URI_LEN - 1);
- if (temp_uri[0] == 0 || !strstr((S8*) temp_uri, (S8*) "@"))
- {
- DisplayPopup(
- (PU8) GetString(STR_ID_POC_NULL_STR_ERR),
- IMG_GLOBAL_UNFINISHED,
- 1,
- CS_NOTIFYDURATION,
- ERROR_TONE);
- return;
- }
- mmi_poc_entry_progressing();
- DeleteUptoScrID(SCR_ID_POC_CONTACT);
- DeleteScreenIfPresent(SCR_ID_POC_CONTACT);
- if (g_poc_cntx_p->curr_contact_op == XDM_PUT_REPLACE)
- {
- cont = &g_poc_cntx_p->contact_list_disp[g_poc_cntx_p->contact_selected];
- memset(
- g_poc_cntx_p->contact_list[cont->group_id].entries[cont->entry_id].uri,
- 0,
- sizeof(g_poc_cntx_p->contact_list[cont->group_id].entries[cont->entry_id].uri));
- UnicodeNToAnsii(
- (S8*) g_poc_cntx_p->contact_list[cont->group_id].entries[cont->entry_id].uri,
- (S8*) g_poc_cntx_p->contact_entry_disp.uri,
- (U32) POC_MAX_URI_LEN - 1);
- memset(
- g_poc_cntx_p->contact_list[cont->group_id].entries[cont->entry_id].display_name,
- 0,
- sizeof(g_poc_cntx_p->contact_list[cont->group_id].entries[cont->entry_id].display_name));
- UnicodeNToAnsii(
- (S8*) g_poc_cntx_p->contact_list[cont->group_id].entries[cont->entry_id].display_name,
- (S8*) g_poc_cntx_p->contact_entry_disp.display_name,
- (U32) POC_MAX_DISP_LEN - 1);
- g_poc_cntx_p->contact_list[cont->group_id].entries[cont->entry_id].allow_invite =
- g_poc_cntx_p->contact_entry_disp.allow_invite;
- memcpy(
- &g_poc_cntx_p->contact_list[cont->group_id].entries[cont->entry_id].auth_rule,
- &g_poc_cntx_p->contact_entry_disp.auth_rule,
- sizeof(poc_pres_authrule_struct));
- if (g_poc_cntx_p->contact_list[cont->group_id].entries[cont->entry_id].sub_pres !=
- g_poc_cntx_p->contact_entry_disp.sub_pres)
- {
- g_poc_cntx_p->contact_list[cont->group_id].entries[cont->entry_id].sub_pres =
- g_poc_cntx_p->contact_entry_disp.sub_pres;
- if (g_poc_cntx_p->curr_use_pres_mode == MMI_TRUE)
- {
- if (g_poc_cntx_p->contact_list[cont->group_id].entries[cont->entry_id].sub_pres == POC_SETTING_TRUE)
- {
- mmi_poc_entry_update_subscribe_req(
- POC_SUBSCRIBE_ACTION,
- g_poc_cntx_p->contact_list[cont->group_id].entries[cont-> entry_id]. uri);
- SetProtocolEventHandler(
- mmi_poc_update_subscribe_success_rsp,
- MSG_ID_POC_PRESENCE_SUBSCRIBE_RSP);
- }
- else if (g_poc_cntx_p->contact_list[cont->group_id].entries[cont->entry_id].sub_pres ==
- POC_SETTING_FALSE)
- {
- mmi_poc_entry_update_subscribe_req(
- POC_UNSUBSCRIBE_ACTION,
- g_poc_cntx_p->contact_list[cont->group_id].entries[cont-> entry_id]. uri);
- SetProtocolEventHandler(
- mmi_poc_update_subscribe_success_rsp,
- MSG_ID_POC_PRESENCE_SUBSCRIBE_RSP);
- }
- else
- {
- g_poc_cntx_p->progressing.contact = MMI_FALSE;
- if (GetActiveScreenId() == SCR_ID_POC_GENERAL_PROGRESSING)
- {
- DisplayPopup(
- (U8*) GetString(STR_GLOBAL_DONE),
- IMG_GLOBAL_ACTIVATED,
- 1,
- UI_POPUP_NOTIFYDURATION_TIME,
- (U8) SUCCESS_TONE);
- }
- DeleteScreenIfPresent(SCR_ID_POC_GENERAL_PROGRESSING);
- }
- }
- else
- {
- g_poc_cntx_p->progressing.contact = MMI_FALSE;
- if (GetActiveScreenId() == SCR_ID_POC_GENERAL_PROGRESSING)
- {
- DisplayPopup(
- (U8*) GetString(STR_GLOBAL_DONE),
- IMG_GLOBAL_ACTIVATED,
- 1,
- UI_POPUP_NOTIFYDURATION_TIME,
- (U8) SUCCESS_TONE);
- }
- DeleteScreenIfPresent(SCR_ID_POC_GENERAL_PROGRESSING);
- }
- }
- else
- {
- g_poc_cntx_p->progressing.contact = MMI_FALSE;
- if (GetActiveScreenId() == SCR_ID_POC_GENERAL_PROGRESSING)
- {
- DisplayPopup(
- (U8*) GetString(STR_GLOBAL_DONE),
- IMG_GLOBAL_ACTIVATED,
- 1,
- UI_POPUP_NOTIFYDURATION_TIME,
- (U8) SUCCESS_TONE);
- }
- DeleteScreenIfPresent(SCR_ID_POC_GENERAL_PROGRESSING);
- }
- }
- else
- {
- #ifdef __MMI_POC_ALWAYS_CREATE_MTK_CONTACT__
- for (i = 0; i < MAX_POC_GROUP_FILE_NUM * MAX_POC_GROUPS_PER_FILE_NUM; i++)
- {
- if (g_poc_cntx_p->contact_list[i].valid == MMI_TRUE)
- {
- if (!strcmp((S8*) g_poc_cntx_p->contact_list[i].list_name, (S8*) POC_MTK_DEFAULT_CONTACT))
- {
- break;
- }
- }
- }
- ASSERT(i != MAX_POC_GROUP_FILE_NUM * MAX_POC_GROUPS_PER_FILE_NUM);
- #else /* __MMI_POC_ALWAYS_CREATE_MTK_CONTACT__ */
- i = g_poc_cntx_p->update_grp_idx;
- #endif /* __MMI_POC_ALWAYS_CREATE_MTK_CONTACT__ */
- new_idx = g_poc_cntx_p->contact_list[i].no_entries;
- memset(
- g_poc_cntx_p->contact_list[i].entries[new_idx].uri,
- 0,
- sizeof(g_poc_cntx_p->contact_list[i].entries[new_idx].uri));
- UnicodeNToAnsii(
- (S8*) g_poc_cntx_p->contact_list[i].entries[new_idx].uri,
- (S8*) g_poc_cntx_p->contact_entry_disp.uri,
- (U32) POC_MAX_URI_LEN - 1);
- memset(
- g_poc_cntx_p->contact_list[i].entries[new_idx].display_name,
- 0,
- sizeof(g_poc_cntx_p->contact_list[i].entries[new_idx].display_name));
- UnicodeNToAnsii(