From 9944f993f4c03bdc506d00a5ffd7d2641842940d Mon Sep 17 00:00:00 2001 From: Soonmin Jung Date: Fri, 24 Aug 2012 13:28:40 +0900 Subject: [PATCH] remove the "Numbers to reject" menu. --- .../src/general/msg-ui-setting-general-setting.c | 81 +--------------------- 1 file changed, 2 insertions(+), 79 deletions(-) diff --git a/setting/src/general/msg-ui-setting-general-setting.c b/setting/src/general/msg-ui-setting-general-setting.c index 6828b44..8fc6009 100755 --- a/setting/src/general/msg-ui-setting-general-setting.c +++ b/setting/src/general/msg-ui-setting-general-setting.c @@ -20,7 +20,6 @@ static struct _msg_ui_setting_mixed_list_item general_menu_its[] = { - { 1, "Numbers to reject", NULL, ELM_GENLIST_ITEM_NONE }, { 1, "Blocked word", msg_ui_setting_general_block_message_main, ELM_GENLIST_ITEM_NONE }, /* do not delete below */ { 1, NULL, NULL, ELM_GENLIST_ITEM_NONE } @@ -31,8 +30,6 @@ static struct _msg_ui_setting_mixed_list_item general_menu_its[] = { STATIC FUNCTION DEFINE =============================================================================*/ static char *__msg_ui_setting_general_gl_text_get(void *data, Evas_Object *obj, const char *part); -static void __msg_ui_setting_general_layout_cb(ui_gadget_h ug, enum ug_mode mode, void *priv); -static void __msg_ui_setting_general_destroy_cb(ui_gadget_h ug, void *priv); static void __msg_ui_setting_general_gl_sel(void *data, Evas_Object *obj, void *event_info); static Evas_Object *__msg_ui_setting_general_create_menu(Evas_Object *parent, PMSG_SETTING_DATA settingData); static void __msg_ui_setting_general_back_btn_cb(void *data, Evas_Object *obj, void *event_info); @@ -66,55 +63,6 @@ __msg_ui_setting_general_gl_text_get(void *data, Evas_Object *obj, const char *p } static void -__msg_ui_setting_general_layout_cb(ui_gadget_h ug, enum ug_mode mode, void *priv) -{ - MSG_UI_ENTER(MSG_UI_LEVEL_DEBUG); - MSG_UI_RET_IF(MSG_UI_LEVEL_ERR, !ug); - MSG_UI_RET_IF(MSG_UI_LEVEL_ERR, !priv); - - Evas_Object *base; - - base = ug_get_layout(ug); - - if (!base) - return; - - switch (mode) { - case UG_MODE_FULLVIEW: - evas_object_size_hint_weight_set(base, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); - elm_win_resize_object_add(ug_get_window(), base); - evas_object_show(base); - break; - case UG_MODE_FRAMEVIEW: - default: - break; - } - - MSG_UI_LEAVE(MSG_UI_LEVEL_DEBUG); -} - -static void -__msg_ui_setting_general_destroy_cb(ui_gadget_h ug, void *priv) -{ - MSG_UI_ENTER(MSG_UI_LEVEL_DEBUG); - MSG_UI_RET_IF(MSG_UI_LEVEL_ERR, !ug); - MSG_UI_RET_IF(MSG_UI_LEVEL_ERR, !priv); - - PMSG_SETTING_DATA settingData = (PMSG_SETTING_DATA) priv; - - settingData->loaded_ug = ug; - - if (settingData->loaded_ug) { - ug_destroy(settingData->loaded_ug); - settingData->loaded_ug = NULL; - } - - evas_object_show(settingData->layout_main); - - MSG_UI_LEAVE(MSG_UI_LEVEL_DEBUG); -} - -static void __msg_ui_setting_general_gl_sel(void *data, Evas_Object *obj, void *event_info) { MSG_UI_ENTER(MSG_UI_LEVEL_DEBUG); @@ -127,33 +75,8 @@ __msg_ui_setting_general_gl_sel(void *data, Evas_Object *obj, void *event_info) elm_genlist_item_selected_set((Elm_Object_Item *)event_info, EINA_FALSE); - if (index == MSG_UI_SETTING_GENERAL_MENU_NUMBERS_TO_REJECT) { - settingData->cbs.layout_cb = __msg_ui_setting_general_layout_cb; - settingData->cbs.result_cb = NULL; - settingData->cbs.destroy_cb = __msg_ui_setting_general_destroy_cb; - settingData->cbs.priv = (void *)settingData; - - if (settingData->loaded_ug != NULL) { - MSG_UI_DEBUG(MSG_UI_LEVEL_ERR, "other ug already exist"); - return; - } - - /* Call auto reject list UG. */ - service_h svc_handle; - service_error_e scv_error = service_create(&svc_handle); - - if (scv_error == SERVICE_ERROR_NONE) { - service_add_extra_data(svc_handle, MSG_BUNDLE_KEY_TYPE, MSG_BUNDLE_VALUE_AUTO_REJECT_LIST); - settingData->loaded_ug = ug_create(settingData->ug, CALL_SETTING_UG_NAME, UG_MODE_FULLVIEW, svc_handle, &settingData->cbs); - service_destroy(svc_handle); - } else { - MSG_UI_DEBUG(MSG_UI_LEVEL_ERR, "service_create() is failed!!"); - return; - } - } else { - if (general_menu_its[index].func != NULL) - general_menu_its[index].func(settingData, obj, event_info); - } + if (general_menu_its[index].func != NULL) + general_menu_its[index].func(settingData, obj, event_info); MSG_UI_LEAVE(MSG_UI_LEVEL_DEBUG); } -- 2.7.4