From: Minsoo Kim Date: Thu, 6 Dec 2012 12:59:16 +0000 (+0900) Subject: apply efl migration X-Git-Tag: 2.1b_release~3^2~77 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=8088458b63f426a7b9fed10f2c4ba8b9624dedd5;p=apps%2Fhome%2Femail.git apply efl migration --- diff --git a/setting/CMakeLists.txt b/setting/CMakeLists.txt index b70fa41..4eaede7 100755 --- a/setting/CMakeLists.txt +++ b/setting/CMakeLists.txt @@ -31,7 +31,7 @@ INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/common/include) INCLUDE(FindPkgConfig) pkg_check_modules(pkgs-setting REQUIRED ecore glib-2.0 gobject-2.0 elementary utilX vconf - appcore-efl email-service ui-gadget-1 bundle dlog edbus capi-appfw-application status libxml-2.0) + appcore-efl email-service ui-gadget-1 bundle dlog edbus capi-appfw-application status libxml-2.0 contacts-service2) FOREACH(flag ${pkgs-setting_CFLAGS}) SET(EXTRA_CFLAGS "${EXTRA_CFLAGS} ${flag}") diff --git a/setting/include/email-setting.h b/setting/include/email-setting.h index b6b0e08..7825571 100755 --- a/setting/include/email-setting.h +++ b/setting/include/email-setting.h @@ -56,10 +56,10 @@ #define ACCOUNT_ICON_HOTMAIL IMGDIR"/M02_email_list_icon_hotmail.png" #define ACCOUNT_ICON_YAHOO IMGDIR"/M02_email_list_icon_YahooMail.png" #define ACCOUNT_ICON_AOL IMGDIR"/M02_email_list_icon_AOL.png" -#define ACCOUNT_ICON_OTHERS IMGDIR"/icon_email.png" +#define ACCOUNT_ICON_OTHERS IMGDIR"/M02_title_icon_others.png" #define CBAR_ICON_ADD IMGDIR"/01_controlbar_icon_create_folder.png" -#define TITLE_ICON_REFRESH IMGDIR"/M02_email_icon_title_refresh.png" +#define TITLE_ICON_REFRESH IMGDIR"/00_icon_refresh.png" #define SP_XML_PATH RESDIR"/xml/sp_list.xml" @@ -81,11 +81,18 @@ struct sp_desc { int rgb; }; +enum { + PRIORITY_SENDER_MODE_ADD = 1, + PRIORITY_SENDER_MODE_EDIT, + PRIORITY_SENDER_MODE_MAX +}; typedef struct ug_data EmailSettingUGD; struct ug_data { ui_gadget_h ug; ui_gadget_h ug_block; ui_gadget_h ug_cert; + ui_gadget_h ug_contact; + ui_gadget_h ug_myfiles; struct ug_cbs block_cbs; struct ug_cbs eas_cbs; @@ -119,6 +126,8 @@ struct ug_data { email_account_t *new_account; email_account_t *account_list; + email_rule_t *rule; + int err_code; int account_count; int account_id; @@ -141,6 +150,7 @@ struct ug_data { int b_on_pause; int wds_account_creation; int manual_setup; + int mode; int handle; diff --git a/setting/src/email-setting-account-set.c b/setting/src/email-setting-account-set.c index eae933e..a5ce007 100755 --- a/setting/src/email-setting-account-set.c +++ b/setting/src/email-setting-account-set.c @@ -238,8 +238,9 @@ static void _set_others_email(struct viewdata *vd) int rgb = 0x006400ff; - _set_display_name_with_email_addr(account->user_email_address, &(account->user_display_name)); - _set_user_name_with_email_addr(account->user_email_address, &(account->incoming_server_user_name)); + //_set_display_name_with_email_addr(account->user_email_address, &(account->user_display_name)); + //_set_user_name_with_email_addr(account->user_email_address, &(account->incoming_server_user_name)); + account->user_display_name = g_strdup(account->incoming_server_user_name); account->reply_to_address = g_strdup(account->user_email_address); account->return_address = g_strdup(account->user_email_address); diff --git a/setting/src/email-setting-utils.c b/setting/src/email-setting-utils.c index b0fb600..ffaf2a4 100755 --- a/setting/src/email-setting-utils.c +++ b/setting/src/email-setting-utils.c @@ -312,9 +312,9 @@ Evas_Object *setting_get_small_notify(struct viewdata *vd, char *label) } ugd->small_noti = elm_notify_add(ugd->layout_main); - elm_notify_orient_set(ugd->small_noti, ELM_NOTIFY_ORIENT_BOTTOM); + elm_notify_align_set(ugd->small_noti, ELM_NOTIFY_ALIGN_FILL, 1.0); ugd->small_noti_ly = elm_layout_add(ugd->layout_main); - elm_layout_theme_set(ugd->small_noti_ly, "standard", "selectioninfo", "vertical/bottom_64"); + elm_layout_theme_set(ugd->small_noti_ly, "standard", "selectioninfo", "center_text"); elm_object_content_set(ugd->small_noti, ugd->small_noti_ly); char text[128] = {0,}; snprintf(text, sizeof(text), "%s", label); diff --git a/setting/src/email-setting.c b/setting/src/email-setting.c index 39ea457..8ed3051 100755 --- a/setting/src/email-setting.c +++ b/setting/src/email-setting.c @@ -149,6 +149,7 @@ static void *on_create(ui_gadget_h ug, enum ug_mode mode, service_h service, voi evas_object_smart_callback_add(ugd->win, "profile,changed", _win_profile_changed_cb, ugd); _create_navigationbar(ugd); ugd->base = ugd->layout_main; + elm_win_indicator_mode_set(ugd->win, ELM_WIN_INDICATOR_SHOW); return ugd->layout_main; } @@ -736,7 +737,6 @@ static Evas_Object *_create_layout(Evas_Object *parent, struct ug_data *ugd) elm_layout_theme_set(base, "layout", "application", "default"); evas_object_size_hint_weight_set(base, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); - elm_win_resize_object_add(parent, base); evas_object_show(base); elm_object_style_set(ugd->bg, "group_list"); @@ -762,7 +762,6 @@ static void _win_profile_changed_cb(void *data, Evas_Object *obj, void *event) elm_layout_theme_set(ugd->layout_main, "layout", "application", "default"); evas_object_size_hint_weight_set(ugd->layout_main, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); - elm_win_resize_object_add(ugd->win, ugd->layout_main); evas_object_show(ugd->layout_main); } @@ -784,7 +783,6 @@ static void _layout_block_cb(ui_gadget_h ug, enum ug_mode mode, void *priv) switch (mode) { case UG_MODE_FULLVIEW: evas_object_size_hint_weight_set(base, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); - elm_win_resize_object_add(ugd->win, base); evas_object_show(base); break; default: diff --git a/setting/src/email-view-account-edit.c b/setting/src/email-view-account-edit.c index d5c429a..a1c5b4a 100755 --- a/setting/src/email-view-account-edit.c +++ b/setting/src/email-view-account-edit.c @@ -102,6 +102,7 @@ struct priv_data { Evas_Object *l_button; Evas_Object *r_button1; Evas_Object *r_button2; + Evas_Object *tool_btn; Evas_Object *clicked_object; Evas_Object *cbar; Evas_Object *onoff[3]; @@ -233,7 +234,6 @@ static int _create(struct viewdata *vd) return FALSE; } - EmailSettingUGD *ugd = vd->ugd; struct priv_data *p; p = vd->priv; @@ -249,13 +249,7 @@ static int _create(struct viewdata *vd) p->layout = setting_add_inner_layout(vd); _push_naviframe(vd); - - elm_win_conformant_set(ugd->win, 1); - p->conform = elm_conformant_add(ugd->win); - elm_object_style_set(p->conform, "internal_layout"); - evas_object_show(p->conform); - - elm_object_part_content_set(p->layout, "elm.swallow.content", p->conform); +// elm_object_part_content_set(ugd->win, "elm.swallow.content", p->layout); } p->b_first_focus_on_pw = 1; @@ -414,7 +408,7 @@ static void _push_naviframe(struct viewdata *vd) debug_log(""); struct priv_data *p = vd->priv; - p->cbar = elm_toolbar_add(vd->ugd->navi_bar); + /*p->cbar = elm_toolbar_add(vd->ugd->navi_bar); elm_toolbar_shrink_mode_set(p->cbar, ELM_TOOLBAR_SHRINK_EXPAND); elm_object_style_set(p->cbar, "naviframe"); evas_object_show(p->cbar); @@ -422,13 +416,13 @@ static void _push_naviframe(struct viewdata *vd) p->c_item[0] = elm_toolbar_item_append(p->cbar, NULL, dgettext("sys_string", "IDS_COM_SK_SET"), _save_cb, vd); elm_object_item_disabled_set(elm_toolbar_item_append(p->cbar, NULL, "", NULL, NULL), EINA_TRUE); - elm_object_item_disabled_set(elm_toolbar_item_append(p->cbar, NULL, "", NULL, NULL), EINA_TRUE); + elm_object_item_disabled_set(elm_toolbar_item_append(p->cbar, NULL, "", NULL, NULL), EINA_TRUE);*/ p->l_button = elm_button_add(vd->ugd->navi_bar); - elm_object_style_set(p->l_button, "naviframe/title/default"); - elm_object_text_set(p->l_button, dgettext("sys_string", "IDS_COM_SK_CANCEL")); + //elm_object_style_set(p->l_button, "naviframe/title/default"); + elm_object_style_set(p->l_button, "naviframe/back_btn/default"); + //elm_object_text_set(p->l_button, dgettext("sys_string", "IDS_COM_SK_CANCEL")); evas_object_smart_callback_add(p->l_button, "clicked", _back_cb, vd); - /*elm_object_style_set(p->l_button, "naviframe/back_btn/default");*/ evas_object_show(p->l_button); /*p->r_button1 = elm_button_add(vd->ugd->navi_bar); @@ -443,11 +437,21 @@ static void _push_naviframe(struct viewdata *vd) evas_object_smart_callback_add(p->r_button2, "clicked", _save_cb, vd); evas_object_show(p->r_button2);*/ + p->tool_btn = elm_button_add(vd->ugd->navi_bar); + elm_object_style_set(p->tool_btn, "naviframe/toolbar/default"); + elm_object_text_set(p->tool_btn, dgettext("sys_string", "IDS_COM_SK_SET")); + evas_object_smart_callback_add(p->tool_btn, "clicked", _save_cb, vd); + Evas_Object *title_ic = elm_icon_add(vd->ugd->navi_bar); evas_object_size_hint_aspect_set(title_ic, EVAS_ASPECT_CONTROL_VERTICAL, 1, 1); elm_icon_resizable_set(title_ic, EINA_TRUE, EINA_TRUE); - elm_icon_file_set(title_ic, account_data->logo_icon_path, NULL); - + + if (account_data->incoming_server_type == EMAIL_SERVER_TYPE_ACTIVE_SYNC) { + elm_icon_file_set(title_ic, ACCOUNT_ICON_EXCHANGE, NULL); + } else { + elm_icon_file_set(title_ic, account_data->logo_icon_path, NULL); + } + account_user_data_t *user_data = (account_user_data_t *)account_data->user_data; Elm_Object_Item *navi_it = NULL; @@ -456,7 +460,7 @@ static void _push_naviframe(struct viewdata *vd) elm_object_item_part_content_set(navi_it, "title_right_btn", p->r_button2);*/ if (user_data->is_preset_account != 0) elm_object_item_part_content_set(navi_it, "icon", title_ic); - elm_object_item_part_content_set(navi_it, "controlbar", p->cbar); + elm_object_item_part_content_set(navi_it, "toolbar_button1", p->tool_btn); evas_object_show(vd->ugd->navi_bar); } @@ -550,7 +554,7 @@ static void _create_list(struct viewdata *vd) elm_genlist_item_select_mode_set(git, ELM_OBJECT_SELECT_MODE_DISPLAY_ONLY); /* account name */ i = 1; - item = elm_genlist_item_append(p->genlist, &(p->itc_ef), (void *)i, NULL, + elm_genlist_item_append(p->genlist, &(p->itc_ef), (void *)i, NULL, ELM_GENLIST_ITEM_NONE, _gl_ef_sel_cb, (void *)i); /* email address */ i = 2; @@ -564,7 +568,7 @@ static void _create_list(struct viewdata *vd) elm_object_item_disabled_set(item, EINA_TRUE); /* password */ i = 4; - item = elm_genlist_item_append(p->genlist, &(p->itc_ef), (void *)i, NULL, + elm_genlist_item_append(p->genlist, &(p->itc_ef), (void *)i, NULL, ELM_GENLIST_ITEM_NONE, _gl_ef_sel_cb, (void *)i); git = elm_genlist_item_append(p->genlist, &(p->itc_sep), NULL, NULL, @@ -572,11 +576,11 @@ static void _create_list(struct viewdata *vd) elm_genlist_item_select_mode_set(git, ELM_OBJECT_SELECT_MODE_DISPLAY_ONLY); /* smtp server */ i = 5; - item = elm_genlist_item_append(p->genlist, &(p->itc_ef), (void *)i, NULL, + elm_genlist_item_append(p->genlist, &(p->itc_ef), (void *)i, NULL, ELM_GENLIST_ITEM_NONE, _gl_ef_sel_cb, (void *)i); /* smtp port */ i = 6; - item = elm_genlist_item_append(p->genlist, &(p->itc_ef), (void *)i, NULL, + elm_genlist_item_append(p->genlist, &(p->itc_ef), (void *)i, NULL, ELM_GENLIST_ITEM_NONE, _gl_ef_sel_cb, (void *)i); /* sending security */ i = 1; @@ -594,11 +598,11 @@ static void _create_list(struct viewdata *vd) /* incoming server */ i = 7; - item = elm_genlist_item_append(p->genlist, &(p->itc_ef), (void *)i, NULL, + elm_genlist_item_append(p->genlist, &(p->itc_ef), (void *)i, NULL, ELM_GENLIST_ITEM_NONE, _gl_ef_sel_cb, (void *)i); /* incoming port */ i = 8; - item = elm_genlist_item_append(p->genlist, &(p->itc_ef), (void *)i, NULL, + elm_genlist_item_append(p->genlist, &(p->itc_ef), (void *)i, NULL, ELM_GENLIST_ITEM_NONE, _gl_ef_sel_cb, (void *)i); /* secure connection */ i = 2; @@ -612,12 +616,12 @@ static void _create_list(struct viewdata *vd) /* SMTP Authentication */ /* POP before SMTP */ i = 0; - item = elm_genlist_item_append(p->genlist, &(p->itc_onoff), (void *)i, git, + elm_genlist_item_append(p->genlist, &(p->itc_onoff), (void *)i, git, ELM_GENLIST_ITEM_NONE, _gl_onoff_sel_cb, (void *)i); /* SMTP Auth */ i = 1; - item = elm_genlist_item_append(p->genlist, &(p->itc_onoff), (void *)i, git, + elm_genlist_item_append(p->genlist, &(p->itc_onoff), (void *)i, git, ELM_GENLIST_ITEM_NONE, _gl_onoff_sel_cb, (void *)i); /* Same as POP3/IMAP4 */ @@ -646,7 +650,7 @@ static void _create_list(struct viewdata *vd) evas_object_smart_callback_add(p->genlist, "expanded", _gl_exp_cb, (void *)vd); evas_object_smart_callback_add(p->genlist, "contracted", _gl_con_cb, (void *)vd); - elm_object_content_set(p->conform, p->genlist); + elm_object_part_content_set(p->layout, "elm.swallow.content", p->genlist); } static void _get_selected_account_details(struct viewdata *vd) @@ -894,7 +898,7 @@ static void _validate_account(struct viewdata *vd, int account_id) } elm_object_disabled_set(p->l_button, EINA_TRUE); - elm_object_item_disabled_set(p->c_item[0], EINA_TRUE); + elm_object_disabled_set(p->tool_btn, EINA_TRUE); if (ret) { debug_log("Start Account Validation"); @@ -1055,7 +1059,7 @@ static void _popup_ok_cb(void *data, Evas_Object *obj, void *event_info) } elm_object_disabled_set(p->l_button, EINA_FALSE); - elm_object_item_disabled_set(p->c_item[0], EINA_FALSE); + elm_object_disabled_set(p->tool_btn, EINA_FALSE); } static void _popup_cancel_validation_cb(void *data, Evas_Object *obj, void *event_info) @@ -1084,7 +1088,7 @@ static void _popup_cancel_validation_cb(void *data, Evas_Object *obj, void *even /*int account_id = vd->ugd->account_id;*/ vd->ugd->cancel_event = 1; elm_object_disabled_set(p->l_button, EINA_FALSE); - elm_object_item_disabled_set(p->c_item[0], EINA_FALSE); + elm_object_disabled_set(p->tool_btn, EINA_FALSE); /*email_engine_stop_working(account_id,p->handle);*/ } @@ -1377,11 +1381,11 @@ static char *_gl_onoff_text_get_cb(void *data, Evas_Object *obj, const char *par char buf[MAX_STR_LEN] = { 0, }; if (index == 0) { - snprintf(buf, sizeof(buf), "%s", N_("POP before SMTP")); + snprintf(buf, sizeof(buf), "%s", _("IDS_EMAIL_BODY_POP3_BEFORE_SMTP")); } if (index == 1) { - snprintf(buf, sizeof(buf), "%s", N_("SMTP Auth.")); + snprintf(buf, sizeof(buf), "%s", _("IDS_EMAIL_BODY_SMTP_AUTHENTICATION")); } if (index == 2) { diff --git a/setting/src/email-view-account-options.c b/setting/src/email-view-account-options.c index c7a5ebe..db06993 100755 --- a/setting/src/email-view-account-options.c +++ b/setting/src/email-view-account-options.c @@ -78,7 +78,6 @@ struct priv_data { Evas_Object *l_button; Evas_Object *layout; - Evas_Object *conform; Evas_Object *ef; Evas_Object *ef_bk; @@ -154,13 +153,7 @@ static int _create(struct viewdata *vd) _print_option_details(); p->layout = setting_add_inner_layout(vd); _push_naviframe(vd); - - elm_win_conformant_set(ugd->win, 1); - p->conform = elm_conformant_add(ugd->win); - elm_object_style_set(p->conform, "internal_layout"); - evas_object_show(p->conform); - - elm_object_part_content_set(p->layout, "elm.swallow.content", p->conform); +// elm_object_part_content_set(ugd->win, "elm.swallow.content", p->layout); } g_vd = vd; @@ -283,10 +276,10 @@ static void _push_naviframe(struct viewdata *vd) struct priv_data *p = vd->priv; p->l_button = elm_button_add(vd->ugd->navi_bar); + elm_object_style_set(p->l_button, "naviframe/back_btn/default"); evas_object_smart_callback_add(p->l_button, "clicked", _back_cb, vd); elm_naviframe_item_push(vd->ugd->navi_bar, _("IDS_EMAIL_HEADER_ACCOUNT_SETTINGS"), p->l_button, NULL, p->layout, NULL); - elm_object_style_set(p->l_button, "naviframe/back_btn/default"); evas_object_show(vd->ugd->navi_bar); } @@ -324,7 +317,7 @@ static void _create_list(struct viewdata *vd) p->genlist = elm_genlist_add(ugd->navi_bar); elm_object_style_set(p->genlist, "dialogue"); - p->itc_account.item_style = "dialogue/2text.3icon"; + p->itc_account.item_style = "dialogue/2text.2icon.3.tb";//dialogue/2text.3icon"; p->itc_account.func.text_get = _gl_account_text_get_cb; p->itc_account.func.content_get = _gl_account_content_get_cb; p->itc_account.func.state_get = NULL; @@ -549,7 +542,7 @@ static void _create_list(struct viewdata *vd) evas_object_smart_callback_add(p->genlist, "expanded", _gl_exp_cb, (void *)vd); evas_object_smart_callback_add(p->genlist, "contracted", _gl_con_cb, (void *)vd); - elm_object_content_set(p->conform, p->genlist); + elm_object_part_content_set(p->layout, "elm.swallow.content", p->genlist); } static void _update_account_info(struct viewdata *vd) @@ -891,11 +884,11 @@ static char *_gl_onoff_text_get_cb(void *data, Evas_Object *obj, const char *par } if (index == 2) { - snprintf(buf, sizeof(buf), "%s", N_("Request read report")); + snprintf(buf, sizeof(buf), "%s", _("IDS_EMAIL_BODY_REQUEST_READ_REPORTS")); } if (index == 3) { - snprintf(buf, sizeof(buf), "%s", _("IDS_EMAIL_BODY_REQUEST_DELIVERY_REPORT")); + snprintf(buf, sizeof(buf), "%s", _("IDS_EMAIL_BODY_REQUEST_DELIVERY_REPORT")); //IDS_EMAIL_BODY_REQUEST_DELIVERY_REPORTS will be used after translation. } if (index == 4) { diff --git a/setting/src/email-view-account-setup.c b/setting/src/email-view-account-setup.c index df8b8e3..54038c9 100755 --- a/setting/src/email-view-account-setup.c +++ b/setting/src/email-view-account-setup.c @@ -86,12 +86,12 @@ struct priv_data { Evas_Object *ef_password; Evas_Object *layout; - Evas_Object *conform; Evas_Object *scroller; Evas_Object *l_button; Evas_Object *r_button; Evas_Object *r_button2; + Evas_Object *tool_btn; Evas_Object *manual_btn; Evas_Object *icon; Evas_Object *show_passwd_check; @@ -219,13 +219,7 @@ static int _create(struct viewdata *vd) elm_scroller_policy_set(p->scroller, ELM_SCROLLER_POLICY_OFF, ELM_SCROLLER_POLICY_OFF); evas_object_show(p->scroller); - elm_win_conformant_set(ugd->win, EINA_TRUE); - p->conform = elm_conformant_add(ugd->win); - elm_object_style_set(p->conform, "internal_layout"); - elm_object_content_set(p->conform, p->scroller); - evas_object_show(p->conform); - - elm_object_part_content_set(p->layout, "elm.swallow.content", p->conform); + elm_object_part_content_set(p->layout, "elm.swallow.content", p->scroller); } g_vd = vd; @@ -267,7 +261,7 @@ static int _destroy(struct viewdata *vd) evas_object_del(p->l_button); evas_object_del(p->r_button); evas_object_del(p->genlist); - evas_object_del(p->cbar); + evas_object_del(p->tool_btn); if (ugd->password_timer) { ecore_timer_del(ugd->password_timer); @@ -332,24 +326,24 @@ static void _push_naviframe(struct viewdata *vd) debug_log(""); struct priv_data *p = vd->priv; - p->cbar = elm_toolbar_add(vd->ugd->navi_bar); + /*p->cbar = elm_toolbar_add(vd->ugd->navi_bar); elm_toolbar_shrink_mode_set(p->cbar, ELM_TOOLBAR_SHRINK_EXPAND); elm_object_style_set(p->cbar, "naviframe"); evas_object_show(p->cbar); if (vd->ugd->account_info == NULL) { p->c_item[0] = elm_toolbar_item_append(p->cbar, NULL, - dgettext("sys_string", "IDS_COM_SK_NEXT"), _next_cb, vd); + dgettext("sys_string", "IDS_COM_BUTTON_LOGIN"), _next_cb, vd); } else { p->c_item[0] = elm_toolbar_item_append(p->cbar, NULL, dgettext("sys_string", "IDS_COM_BUTTON_LOGIN"), _save_cb, vd); } elm_object_item_disabled_set(p->c_item[0], EINA_TRUE); elm_object_item_disabled_set(elm_toolbar_item_append(p->cbar, NULL, "", NULL, NULL), EINA_TRUE); - elm_object_item_disabled_set(elm_toolbar_item_append(p->cbar, NULL, "", NULL, NULL), EINA_TRUE); + elm_object_item_disabled_set(elm_toolbar_item_append(p->cbar, NULL, "", NULL, NULL), EINA_TRUE);*/ p->l_button = elm_button_add(vd->ugd->navi_bar); - elm_object_style_set(p->l_button, "naviframe/title/default"); + //elm_object_style_set(p->l_button, "naviframe/title/default"); elm_object_focus_allow_set(p->l_button, EINA_FALSE); evas_object_show(p->l_button); @@ -364,18 +358,26 @@ static void _push_naviframe(struct viewdata *vd) elm_object_disabled_set(p->l_button, EINA_TRUE); p->r_button = elm_button_add(vd->ugd->navi_bar); - elm_object_style_set(p->r_button, "naviframe/title/default"); + //elm_object_style_set(p->r_button, "naviframe/title1/default"); elm_object_text_set(p->r_button, dgettext("sys_string", "IDS_COM_SK_CANCEL")); evas_object_smart_callback_add(p->r_button, "clicked", _back_cb, vd); evas_object_show(p->r_button); p->r_button2 = elm_button_add(vd->ugd->navi_bar); - elm_object_style_set(p->r_button2, "naviframe/title/default"); - elm_object_text_set(p->r_button2, dgettext("sys_string", "IDS_COM_SK_CANCEL")); + //elm_object_style_set(p->r_button2, "naviframe/title1/default"); + elm_object_style_set(p->r_button2, "naviframe/back_btn/default"); + //elm_object_text_set(p->r_button2, dgettext("sys_string", "IDS_COM_SK_CANCEL")); evas_object_smart_callback_add(p->r_button2, "clicked", _back_cb, vd); - /*elm_object_style_set(p->r_button2, "naviframe/back_btn/default");*/ evas_object_show(p->r_button2); + p->tool_btn = elm_button_add(vd->ugd->navi_bar); + elm_object_style_set(p->tool_btn, "naviframe/toolbar/default"); + elm_object_text_set(p->tool_btn, dgettext("sys_string", "IDS_COM_BUTTON_LOGIN")); + if (vd->ugd->account_info == NULL) { + evas_object_smart_callback_add(p->tool_btn, "clicked", _next_cb, vd); + } else { + evas_object_smart_callback_add(p->tool_btn, "clicked", _save_cb, vd); + } Evas_Object *title_ic = elm_icon_add(vd->ugd->navi_bar); evas_object_size_hint_aspect_set(title_ic, EVAS_ASPECT_CONTROL_VERTICAL, 1, 1); @@ -392,15 +394,15 @@ static void _push_naviframe(struct viewdata *vd) elm_icon_file_set(title_ic, vd->ugd->account_info->icon_path, NULL); } else { snprintf(title_str, sizeof(title_str), "%s", dgettext("sys_string", "IDS_COM_BODY_OTHERS")); + elm_icon_file_set(title_ic, ACCOUNT_ICON_OTHERS, NULL); } navi_it = elm_naviframe_item_push(vd->ugd->navi_bar, title_str, p->r_button2, NULL, p->layout, NULL); - if (vd->ugd->account_info) { - elm_object_item_part_content_set(navi_it, "icon", title_ic); - } + elm_object_item_part_content_set(navi_it, "icon", title_ic); + elm_object_item_part_content_set(navi_it, "title_left_btn", p->l_button); elm_object_item_part_content_set(navi_it, "title_right_btn", p->r_button); - elm_object_item_part_content_set(navi_it, "controlbar", p->cbar); + elm_object_item_part_content_set(navi_it, "toolbar_button1", p->tool_btn); p->navi_it = navi_it; evas_object_show(vd->ugd->navi_bar); } @@ -619,10 +621,10 @@ static void _create_validation_popup(struct viewdata *vd, int account_id) elm_object_disabled_set(p->r_button, EINA_TRUE); elm_object_disabled_set(p->r_button2, EINA_TRUE); elm_object_disabled_set(p->manual_btn, EINA_TRUE); - elm_object_item_disabled_set(p->c_item[0], EINA_TRUE); + elm_object_disabled_set(p->tool_btn, EINA_TRUE); debug_log("Start Account Validation"); - ugd->popup_validate = setting_get_pb_notify(vd, + ugd->popup_validate = setting_get_pb_process_notify(vd, _("IDS_EMAIL_POP_VALIDATING_ACCOUNT_ING"), 1, dgettext("sys_string", "IDS_COM_SK_CANCEL"), _popup_cancel_validation_cb, NULL, NULL); @@ -1116,7 +1118,7 @@ static void _back_cb(void *data, Evas_Object *obj, void *event_info) elm_object_disabled_set(p->r_button, EINA_TRUE); elm_object_disabled_set(p->r_button2, EINA_TRUE); elm_object_disabled_set(p->manual_btn, EINA_TRUE); - elm_object_item_disabled_set(p->c_item[0], EINA_TRUE); + elm_object_disabled_set(p->tool_btn, EINA_TRUE); if (!strcmp(vd->ugd->start_view_type, "account-add")) { ug_destroy_me(vd->ugd->ug); @@ -1415,7 +1417,7 @@ static void _popup_ok_cb(void *data, Evas_Object *obj, void *event_info) elm_object_disabled_set(p->r_button, EINA_FALSE); elm_object_disabled_set(p->r_button2, EINA_FALSE); elm_object_disabled_set(p->manual_btn, EINA_FALSE); - elm_object_item_disabled_set(p->c_item[0], EINA_FALSE); + elm_object_disabled_set(p->tool_btn, EINA_FALSE); } static void _popup_cancel_validation_cb(void *data, Evas_Object *obj, void *event_info) @@ -1448,7 +1450,7 @@ static void _popup_cancel_validation_cb(void *data, Evas_Object *obj, void *even elm_object_disabled_set(p->r_button, EINA_FALSE); elm_object_disabled_set(p->r_button2, EINA_FALSE); elm_object_disabled_set(p->manual_btn, EINA_FALSE); - elm_object_item_disabled_set(p->c_item[0], EINA_FALSE); + elm_object_disabled_set(p->tool_btn, EINA_FALSE); } static void _backup_input_cb(void *data, Evas_Object *obj, void *event_info) @@ -1520,14 +1522,14 @@ static void _backup_input_cb(void *data, Evas_Object *obj, void *event_info) if (p->str_account_name == NULL) { elm_object_disabled_set(p->l_button, EINA_TRUE); elm_object_disabled_set(p->manual_btn, EINA_TRUE); - elm_object_item_disabled_set(p->c_item[0], EINA_TRUE); + elm_object_disabled_set(p->tool_btn, EINA_TRUE); return; } if (g_strcmp0(p->str_account_name, "") == 0) { elm_object_disabled_set(p->l_button, EINA_TRUE); elm_object_disabled_set(p->manual_btn, EINA_TRUE); - elm_object_item_disabled_set(p->c_item[0], EINA_TRUE); + elm_object_disabled_set(p->tool_btn, EINA_TRUE); return; } } @@ -1535,18 +1537,18 @@ static void _backup_input_cb(void *data, Evas_Object *obj, void *event_info) if (p->str_email_address == NULL || p->str_password == NULL) { elm_object_disabled_set(p->l_button, EINA_TRUE); elm_object_disabled_set(p->manual_btn, EINA_TRUE); - elm_object_item_disabled_set(p->c_item[0], EINA_TRUE); + elm_object_disabled_set(p->tool_btn, EINA_TRUE); return; } if (g_strcmp0(p->str_email_address, "") == 0 || g_strcmp0(p->str_password, "") == 0) { elm_object_disabled_set(p->l_button, EINA_TRUE); elm_object_disabled_set(p->manual_btn, EINA_TRUE); - elm_object_item_disabled_set(p->c_item[0], EINA_TRUE); + elm_object_disabled_set(p->tool_btn, EINA_TRUE); } else { elm_object_disabled_set(p->l_button, EINA_FALSE); elm_object_disabled_set(p->manual_btn, EINA_FALSE); - elm_object_item_disabled_set(p->c_item[0], EINA_FALSE); + elm_object_disabled_set(p->tool_btn, EINA_FALSE); } } diff --git a/setting/src/email-view-mailbox-mapping.c b/setting/src/email-view-mailbox-mapping.c index 79bca8f..e3f5a0e 100755 --- a/setting/src/email-view-mailbox-mapping.c +++ b/setting/src/email-view-mailbox-mapping.c @@ -48,7 +48,6 @@ struct priv_data { Evas_Object *radio_grp; Evas_Object *genlist; - Evas_Object *cbar; Elm_Object_Item * c_item[4]; Elm_Genlist_Item_Class itc; @@ -142,20 +141,13 @@ static void _push_naviframe(struct viewdata *vd) debug_log(""); struct priv_data *p = vd->priv; - p->cbar = elm_toolbar_add(vd->ugd->navi_bar); - elm_toolbar_shrink_mode_set(p->cbar, ELM_TOOLBAR_SHRINK_EXPAND); - elm_object_style_set(p->cbar, "naviframe"); - evas_object_show(p->cbar); - p->l_button = elm_button_add(vd->ugd->navi_bar); - evas_object_smart_callback_add(p->l_button, "clicked", _back_cb, vd); elm_object_style_set(p->l_button, "naviframe/back_btn/default"); + evas_object_smart_callback_add(p->l_button, "clicked", _back_cb, vd); evas_object_show(p->l_button); - Elm_Object_Item *navi_it = NULL; - navi_it = elm_naviframe_item_push(vd->ugd->navi_bar, + elm_naviframe_item_push(vd->ugd->navi_bar, _("IDS_EMAIL_HEADER_MAILBOX_SETUP"), p->l_button, NULL, p->layout, NULL); - elm_object_item_part_content_set(navi_it, "controlbar", p->cbar); evas_object_show(vd->ugd->navi_bar); } @@ -298,6 +290,8 @@ static void _gl_sel_cb(void *data, Evas_Object *obj, void *event_info) elm_radio_value_set(p->radio_grp, index); debug_log("index %d", index); + email_get_mailbox_by_mailbox_type(ugd->account_id, ugd->setup_mailbox, &p->mailbox_type); + email_set_mailbox_type(p->mailbox_type->mailbox_id, EMAIL_MAILBOX_TYPE_USER_DEFINED); email_set_mailbox_type((p->mailbox_list[index]).mailbox_id, ugd->setup_mailbox); diff --git a/setting/src/email-view-manual-setup.c b/setting/src/email-view-manual-setup.c index 71f1169..0aaa791 100755 --- a/setting/src/email-view-manual-setup.c +++ b/setting/src/email-view-manual-setup.c @@ -96,7 +96,6 @@ struct priv_data { Evas_Object *icon; Evas_Object *layout; - Evas_Object *conform; Evas_Object *sending_secure_radio_grp; Evas_Object *incoming_type_radio_grp; @@ -105,6 +104,7 @@ struct priv_data { Evas_Object *r_button; Evas_Object *l_button; Evas_Object *l_button2; + Evas_Object *tool_btn; Evas_Object *clicked_object; Evas_Object *genlist; Evas_Object *cbar; @@ -246,13 +246,7 @@ static int _create(struct viewdata *vd) p->layout = setting_add_inner_layout(vd); _push_naviframe(vd); - - elm_win_conformant_set(ugd->win, 1); - p->conform = elm_conformant_add(ugd->win); - elm_object_style_set(p->conform, "internal_layout"); - evas_object_show(p->conform); - - elm_object_part_content_set(p->layout, "elm.swallow.content", p->conform); +// elm_object_part_content_set(ugd->win, "elm.swallow.content", p->layout); } g_vd = vd; @@ -288,7 +282,7 @@ static int _destroy(struct viewdata *vd) evas_object_del(p->l_button); evas_object_del(p->r_button); evas_object_del(p->genlist); - evas_object_del(p->cbar); + evas_object_del(p->tool_btn); if (ugd->other_vc_timer) { ecore_timer_del(ugd->other_vc_timer); @@ -339,7 +333,7 @@ static void _push_naviframe(struct viewdata *vd) debug_log(""); struct priv_data *p = vd->priv; - p->cbar = elm_toolbar_add(vd->ugd->navi_bar); + /*p->cbar = elm_toolbar_add(vd->ugd->navi_bar); elm_toolbar_shrink_mode_set(p->cbar, ELM_TOOLBAR_SHRINK_EXPAND); elm_object_style_set(p->cbar, "naviframe"); evas_object_show(p->cbar); @@ -348,28 +342,33 @@ static void _push_naviframe(struct viewdata *vd) dgettext("sys_string", "IDS_COM_SK_SET"), _save_cb, vd); elm_object_item_disabled_set(p->c_item[0], EINA_TRUE); elm_object_item_disabled_set(elm_toolbar_item_append(p->cbar, NULL, "", NULL, NULL), EINA_TRUE); - elm_object_item_disabled_set(elm_toolbar_item_append(p->cbar, NULL, "", NULL, NULL), EINA_TRUE); + elm_object_item_disabled_set(elm_toolbar_item_append(p->cbar, NULL, "", NULL, NULL), EINA_TRUE);*/ p->r_button = elm_button_add(vd->ugd->navi_bar); - elm_object_style_set(p->r_button, "naviframe/title/default"); + //elm_object_style_set(p->r_button, "naviframe/title/default"); elm_object_text_set(p->r_button, dgettext("sys_string", "IDS_COM_SK_SET")); evas_object_smart_callback_add(p->r_button, "clicked", _save_cb, vd); elm_object_disabled_set(p->r_button, EINA_TRUE); evas_object_hide(p->r_button); p->l_button = elm_button_add(vd->ugd->navi_bar); - elm_object_style_set(p->l_button, "naviframe/title/default"); + //elm_object_style_set(p->l_button, "naviframe/title/default"); elm_object_text_set(p->l_button, dgettext("sys_string", "IDS_COM_SK_CANCEL")); evas_object_smart_callback_add(p->l_button, "clicked", _back_cb, vd); evas_object_hide(p->l_button); p->l_button2 = elm_button_add(vd->ugd->navi_bar); - elm_object_style_set(p->l_button2, "naviframe/title/default"); - elm_object_text_set(p->l_button2, dgettext("sys_string", "IDS_COM_SK_CANCEL")); + //elm_object_style_set(p->l_button2, "naviframe/title/default"); + elm_object_style_set(p->l_button2, "naviframe/back_btn/default"); + //elm_object_text_set(p->l_button2, dgettext("sys_string", "IDS_COM_SK_CANCEL")); evas_object_smart_callback_add(p->l_button2, "clicked", _back_cb, vd); - /*elm_object_style_set(p->l_button2, "naviframe/back_btn/default");*/ evas_object_show(p->l_button2); + p->tool_btn = elm_button_add(vd->ugd->navi_bar); + elm_object_style_set(p->tool_btn, "naviframe/toolbar/default"); + elm_object_text_set(p->tool_btn, dgettext("sys_string", "IDS_COM_SK_SET")); + evas_object_smart_callback_add(p->tool_btn, "clicked", _save_cb, vd); + Evas_Object *title_ic = elm_icon_add(vd->ugd->navi_bar); evas_object_size_hint_aspect_set(title_ic, EVAS_ASPECT_CONTROL_VERTICAL, 1, 1); elm_icon_resizable_set(title_ic, EINA_TRUE, EINA_TRUE); @@ -393,7 +392,7 @@ static void _push_naviframe(struct viewdata *vd) } /*elm_object_item_part_content_set(navi_it, "title_left_btn", p->r_button); elm_object_item_part_content_set(navi_it, "title_right_btn", p->l_button);*/ - elm_object_item_part_content_set(navi_it, "controlbar", p->cbar); + elm_object_item_part_content_set(navi_it, "toolbar_button1", p->tool_btn); p->navi_it = navi_it; evas_object_show(vd->ugd->navi_bar); } @@ -545,7 +544,7 @@ static void _create_list(struct viewdata *vd) evas_object_smart_callback_add(p->genlist, "expanded", _gl_exp_cb, (void *)vd); evas_object_smart_callback_add(p->genlist, "contracted", _gl_con_cb, (void *)vd); - elm_object_content_set(p->conform, p->genlist); + elm_object_part_content_set(p->layout, "elm.swallow.content", p->genlist); } static int _create_account(void *data) @@ -633,7 +632,7 @@ static void _validate_account(struct viewdata *vd, int account_id) elm_object_disabled_set(p->r_button, EINA_TRUE); elm_object_disabled_set(p->l_button, EINA_TRUE); elm_object_disabled_set(p->l_button2, EINA_TRUE); - elm_object_item_disabled_set(p->c_item[0], EINA_TRUE); + elm_object_disabled_set(p->tool_btn, EINA_TRUE); debug_log("Start Account Validation"); ugd->popup_validate = setting_get_pb_notify(vd, @@ -940,7 +939,7 @@ static void _popup_ok_cb(void *data, Evas_Object *obj, void *event_info) elm_object_disabled_set(p->r_button, EINA_FALSE); elm_object_disabled_set(p->l_button, EINA_FALSE); elm_object_disabled_set(p->l_button2, EINA_FALSE); - elm_object_item_disabled_set(p->c_item[0], EINA_FALSE); + elm_object_disabled_set(p->tool_btn, EINA_FALSE); } /*static void _popup_cancel_cb(void *data, Evas_Object *obj, void *event_info) @@ -997,7 +996,7 @@ static void _popup_cancel_validation_cb(void *data, Evas_Object *obj, void *even elm_object_disabled_set(p->r_button, EINA_FALSE); elm_object_disabled_set(p->l_button, EINA_FALSE); elm_object_disabled_set(p->l_button2, EINA_FALSE); - elm_object_item_disabled_set(p->c_item[0], EINA_FALSE); + elm_object_disabled_set(p->tool_btn, EINA_FALSE); } static void _backup_input_cb(void *data, Evas_Object *obj, void *event_info) @@ -1073,7 +1072,7 @@ static void _backup_input_cb(void *data, Evas_Object *obj, void *event_info) p->str_incoming_server == NULL || p->str_incoming_port == NULL) { elm_object_disabled_set(p->r_button, EINA_TRUE); - elm_object_item_disabled_set(p->c_item[0], EINA_TRUE); + elm_object_disabled_set(p->tool_btn, EINA_TRUE); return; } @@ -1085,10 +1084,10 @@ static void _backup_input_cb(void *data, Evas_Object *obj, void *event_info) g_strcmp0(p->str_incoming_server, "") == 0 || g_strcmp0(p->str_incoming_port, "") == 0) { elm_object_disabled_set(p->r_button, EINA_TRUE); - elm_object_item_disabled_set(p->c_item[0], EINA_TRUE); + elm_object_disabled_set(p->tool_btn, EINA_TRUE); } else { elm_object_disabled_set(p->r_button, EINA_FALSE); - elm_object_item_disabled_set(p->c_item[0], EINA_FALSE); + elm_object_disabled_set(p->tool_btn, EINA_FALSE); } } diff --git a/setting/src/email-view-setting.c b/setting/src/email-view-setting.c index 2f7c0cf..cb800bc 100755 --- a/setting/src/email-view-setting.c +++ b/setting/src/email-view-setting.c @@ -67,6 +67,7 @@ struct priv_data { Evas_Object *icon; Evas_Object *l_button; Evas_Object *r_button; + Evas_Object *tool_btn; Evas_Object *scroller; Evas_Object *ly; Evas_Object *sp1; @@ -241,7 +242,7 @@ static void _push_naviframe(struct viewdata *vd) debug_log(""); struct priv_data *p = vd->priv; - p->cbar = elm_toolbar_add(vd->ugd->navi_bar); + /*p->cbar = elm_toolbar_add(vd->ugd->navi_bar); elm_toolbar_shrink_mode_set(p->cbar, ELM_TOOLBAR_SHRINK_EXPAND); elm_object_style_set(p->cbar, "naviframe"); evas_object_show(p->cbar); @@ -249,17 +250,22 @@ static void _push_naviframe(struct viewdata *vd) p->c_item[0] = elm_toolbar_item_append(p->cbar, CBAR_ICON_ADD, dgettext("sys_string", "IDS_COM_SK_ADD"), _add_account_cb, vd); elm_object_item_disabled_set(elm_toolbar_item_append(p->cbar, NULL, "", NULL, NULL), EINA_TRUE); - elm_object_item_disabled_set(elm_toolbar_item_append(p->cbar, NULL, "", NULL, NULL), EINA_TRUE); + elm_object_item_disabled_set(elm_toolbar_item_append(p->cbar, NULL, "", NULL, NULL), EINA_TRUE);*/ p->l_button = elm_button_add(vd->ugd->navi_bar); + elm_object_style_set(p->l_button, "naviframe/back_btn/default"); evas_object_smart_callback_add(p->l_button, "clicked", _back_cb, vd); evas_object_show(p->l_button); - elm_object_style_set(p->l_button, "naviframe/back_btn/default"); + + p->tool_btn = elm_button_add(vd->ugd->navi_bar); + elm_object_style_set(p->tool_btn, "naviframe/toolbar/default"); + elm_object_text_set(p->tool_btn, dgettext("sys_string", "IDS_COM_SK_ADD")); + evas_object_smart_callback_add(p->tool_btn, "clicked", _add_account_cb, vd); vd->ugd->navi_main_it = elm_naviframe_item_push(vd->ugd->navi_bar, _("IDS_EMAIL_HEADER_EMAIL_SETTINGS"), p->l_button, NULL, p->layout, NULL); elm_object_item_part_content_set(vd->ugd->navi_main_it, - "controlbar", p->cbar); + "toolbar_button1", p->tool_btn); evas_object_show(vd->ugd->navi_bar); } @@ -311,7 +317,7 @@ static void _create_list(struct viewdata *vd) p->itc3.func.del = _gl_del_cb; /*accounts*/ - p->itc4.item_style = "dialogue/2text.3icon"; + p->itc4.item_style = "dialogue/2text.2icon.3.tb";//"dialogue/2text.3icon"; p->itc4.func.text_get = _gl_account_text_get_cb; p->itc4.func.content_get = _gl_account_content_get_cb; p->itc4.func.state_get = _gl_state_get_cb; @@ -496,7 +502,7 @@ static void _color_rect_cb(void *data, Evas * evas, Evas_Object *obj, void *even int a = val & 0x000000ff; ugd->popup_color = elm_notify_add(ugd->navi_bar); - elm_notify_orient_set(ugd->popup_color, ELM_NOTIFY_ORIENT_BOTTOM); + elm_notify_align_set(ugd->popup_color, ELM_NOTIFY_ALIGN_FILL, 1.0); evas_object_size_hint_weight_set(ugd->popup_color, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); /*elm_popup_buttons_add(ugd->popup_color, 2, dgettext("sys_string", "IDS_COM_SK_OK"), ELM_POPUP_RESPONSE_OK, diff --git a/setting/src/email-view-sp-select.c b/setting/src/email-view-sp-select.c index 6ef26a8..11de7fb 100755 --- a/setting/src/email-view-sp-select.c +++ b/setting/src/email-view-sp-select.c @@ -160,12 +160,11 @@ static void _push_naviframe(struct viewdata *vd) debug_log("args are %s", vd->ugd->start_view_type); p->b_btn = elm_button_add(vd->ugd->navi_bar); - + elm_object_style_set(p->b_btn, "naviframe/back_btn/default"); evas_object_smart_callback_add(p->b_btn, "clicked", _back_cb, vd); elm_naviframe_item_push(vd->ugd->navi_bar, _("IDS_EMAIL_HEADER_ADD_ACCOUNT"), p->b_btn, NULL, p->layout, NULL); - elm_object_style_set(p->b_btn, "naviframe/back_btn/default"); evas_object_show(vd->ugd->navi_bar); } diff --git a/setting/src/email-view-sync-schedule.c b/setting/src/email-view-sync-schedule.c index 839b388..e75f361 100755 --- a/setting/src/email-view-sync-schedule.c +++ b/setting/src/email-view-sync-schedule.c @@ -80,8 +80,8 @@ struct priv_data { Evas_Object *l_button; Evas_Object *r_button; + Evas_Object *tool_btn; Evas_Object *layout; - Evas_Object *conform; Evas_Object *sync_radio_grp; Evas_Object *account_icon; @@ -192,13 +192,7 @@ static int _create(struct viewdata *vd) p->layout = setting_add_inner_layout(vd); _push_naviframe(vd); - - elm_win_conformant_set(ugd->win, 1); - p->conform = elm_conformant_add(ugd->win); - elm_object_style_set(p->conform, "internal_layout"); - evas_object_show(p->conform); - - elm_object_part_content_set(p->layout, "elm.swallow.content", p->conform); +// elm_object_part_content_set(ugd->win, "elm.swallow.content", p->layout); } _get_icu_formatter(); @@ -326,7 +320,7 @@ static void _push_naviframe(struct viewdata *vd) debug_log(""); struct priv_data *p = vd->priv; - p->cbar = elm_toolbar_add(vd->ugd->navi_bar); + /*p->cbar = elm_toolbar_add(vd->ugd->navi_bar); elm_toolbar_shrink_mode_set(p->cbar, ELM_TOOLBAR_SHRINK_EXPAND); elm_object_style_set(p->cbar, "naviframe"); evas_object_show(p->cbar); @@ -334,10 +328,10 @@ static void _push_naviframe(struct viewdata *vd) p->c_item[0] = elm_toolbar_item_append(p->cbar, NULL, dgettext("sys_string", "IDS_COM_SK_DELETE"), _delete_cb, vd); elm_object_item_disabled_set(elm_toolbar_item_append(p->cbar, NULL, "", NULL, NULL), EINA_TRUE); - elm_object_item_disabled_set(elm_toolbar_item_append(p->cbar, NULL, "", NULL, NULL), EINA_TRUE); + elm_object_item_disabled_set(elm_toolbar_item_append(p->cbar, NULL, "", NULL, NULL), EINA_TRUE);*/ p->r_button = elm_button_add(vd->ugd->navi_bar); - elm_object_style_set(p->r_button, "naviframe/title/default"); + elm_object_style_set(p->r_button, "naviframe/title_icon"); /*elm_object_text_set(p->r_button, _("IDS_EMAIL_OPT_REFRESH"));*/ Evas_Object *ic = elm_icon_add(p->r_button); elm_icon_file_set(ic, TITLE_ICON_REFRESH, NULL); @@ -353,23 +347,30 @@ static void _push_naviframe(struct viewdata *vd) } p->l_button = elm_button_add(vd->ugd->navi_bar); - evas_object_smart_callback_add(p->l_button, "clicked", _back_cb, vd); elm_object_style_set(p->l_button, "naviframe/back_btn/default"); + evas_object_smart_callback_add(p->l_button, "clicked", _back_cb, vd); + + p->tool_btn = elm_button_add(vd->ugd->navi_bar); + elm_object_style_set(p->tool_btn, "naviframe/toolbar/default"); + elm_object_text_set(p->tool_btn, dgettext("sys_string", "IDS_COM_SK_DELETE")); + evas_object_smart_callback_add(p->tool_btn, "clicked", _delete_cb, vd); + account_user_data_t *user_data = (account_user_data_t *)account_data->user_data; Evas_Object *title_ic = elm_icon_add(vd->ugd->navi_bar); evas_object_size_hint_aspect_set(title_ic, EVAS_ASPECT_CONTROL_VERTICAL, 1, 1); elm_icon_resizable_set(title_ic, EINA_TRUE, EINA_TRUE); - elm_icon_file_set(title_ic, account_data->logo_icon_path, NULL); - - account_user_data_t *user_data = (account_user_data_t *)account_data->user_data; + if (user_data->is_preset_account > 0) { + elm_icon_file_set(title_ic, account_data->logo_icon_path, NULL); + } else { + elm_icon_file_set(title_ic, ACCOUNT_ICON_OTHERS, NULL); + } Elm_Object_Item *navi_it = NULL; navi_it = elm_naviframe_item_push(vd->ugd->navi_bar, account_data->account_name, p->l_button, NULL, p->layout, NULL); - if (user_data->is_preset_account > 0) { - elm_object_item_part_content_set(navi_it, "icon", title_ic); - } + elm_object_item_part_content_set(navi_it, "icon", title_ic); + elm_object_item_part_content_set(navi_it, "title_right_btn", p->r_button); - elm_object_item_part_content_set(navi_it, "controlbar", p->cbar); + elm_object_item_part_content_set(navi_it, "toolbar_button1", p->tool_btn); evas_object_show(vd->ugd->navi_bar); p->navi_it = navi_it; } @@ -396,13 +397,13 @@ static void _create_list(struct viewdata *vd) p->genlist = elm_genlist_add(ugd->navi_bar); elm_object_style_set(p->genlist, "dialogue"); - p->itc_account.item_style = "dialogue/2text.1icon.6"; + p->itc_account.item_style = "dialogue/2text.1icon.10"; p->itc_account.func.text_get = _gl_account_text_get_cb; p->itc_account.func.content_get = _gl_account_content_get_cb; p->itc_account.func.state_get = NULL; p->itc_account.func.del = NULL; - p->itc_onoff.item_style = "dialogue/2text.1icon.6"; + p->itc_onoff.item_style = "dialogue/2text.1icon.10"; p->itc_onoff.func.text_get = _gl_onoff_text_get_cb; p->itc_onoff.func.content_get = _gl_onoff_content_get_cb; p->itc_onoff.func.state_get = NULL; @@ -465,7 +466,7 @@ static void _create_list(struct viewdata *vd) evas_object_smart_callback_add(p->genlist, "expanded", _gl_exp_cb, (void *)vd); evas_object_smart_callback_add(p->genlist, "contracted", _gl_con_cb, (void *)vd); - elm_object_content_set(p->conform, p->genlist); + elm_object_part_content_set(p->layout, "elm.swallow.content", p->genlist); } static void _update_account_info(struct viewdata *vd) @@ -688,7 +689,7 @@ static void _delete_cb(void *data, Evas_Object *obj, void *event_info) vd->ugd->account_id = account_data->account_id; elm_object_disabled_set(p->l_button, EINA_TRUE); - elm_object_item_disabled_set(p->c_item[0], EINA_TRUE); + elm_object_disabled_set(p->tool_btn, EINA_TRUE); ugd->popup_one = setting_get_notify(vd, NULL, _("IDS_EMAIL_POP_ALL_DATA_RELATED_TO_THIS_ACCOUNT_WILL_BE_DELETED_CONTINUE_Q"), 2, dgettext("sys_string", "IDS_COM_SK_YES"), @@ -767,7 +768,7 @@ static void _popup_cancel_cb(void *data, Evas_Object *obj, void *event_info) } elm_object_disabled_set(p->l_button, EINA_FALSE); - elm_object_item_disabled_set(p->c_item[0], EINA_FALSE); + elm_object_disabled_set(p->tool_btn, EINA_FALSE); } static void _popup_delete_ok_cb(void *data, Evas_Object *obj, void *event_info) @@ -941,7 +942,7 @@ static Evas_Object *_gl_account_content_get_cb(void *data, Evas_Object *obj, con if (!g_strcmp0(part, "elm.icon")) { if (p->syncing) { Evas_Object *pb = elm_progressbar_add(ugd->navi_bar); - elm_object_style_set(pb, "list_process_small"); + elm_object_style_set(pb, "list_process"); elm_progressbar_horizontal_set(pb, EINA_TRUE); elm_progressbar_pulse(pb, EINA_TRUE); return pb; diff --git a/setting/src/email-view-sync-setup.c b/setting/src/email-view-sync-setup.c index bcb63b3..211082c 100755 --- a/setting/src/email-view-sync-setup.c +++ b/setting/src/email-view-sync-setup.c @@ -80,8 +80,8 @@ struct priv_data { Evas_Object *l_button; Evas_Object *r_button; + Evas_Object *tool_btn; Evas_Object *layout; - Evas_Object *conform; Evas_Object *sync_radio_grp; Evas_Object *account_icon; @@ -192,13 +192,7 @@ static int _create(struct viewdata *vd) p->layout = setting_add_inner_layout(vd); _push_naviframe(vd); - - elm_win_conformant_set(ugd->win, 1); - p->conform = elm_conformant_add(ugd->win); - elm_object_style_set(p->conform, "internal_layout"); - evas_object_show(p->conform); - - elm_object_part_content_set(p->layout, "elm.swallow.content", p->conform); +// elm_object_part_content_set(ugd->win, "elm.swallow.content", p->layout); } _get_icu_formatter(); @@ -326,7 +320,7 @@ static void _push_naviframe(struct viewdata *vd) debug_log(""); struct priv_data *p = vd->priv; - p->cbar = elm_toolbar_add(vd->ugd->navi_bar); + /*p->cbar = elm_toolbar_add(vd->ugd->navi_bar); elm_toolbar_shrink_mode_set(p->cbar, ELM_TOOLBAR_SHRINK_EXPAND); elm_object_style_set(p->cbar, "naviframe"); evas_object_show(p->cbar); @@ -334,10 +328,10 @@ static void _push_naviframe(struct viewdata *vd) p->c_item[0] = elm_toolbar_item_append(p->cbar, NULL, dgettext("sys_string", "IDS_COM_SK_DELETE"), _delete_cb, vd); elm_object_item_disabled_set(elm_toolbar_item_append(p->cbar, NULL, "", NULL, NULL), EINA_TRUE); - elm_object_item_disabled_set(elm_toolbar_item_append(p->cbar, NULL, "", NULL, NULL), EINA_TRUE); + elm_object_item_disabled_set(elm_toolbar_item_append(p->cbar, NULL, "", NULL, NULL), EINA_TRUE);*/ p->r_button = elm_button_add(vd->ugd->navi_bar); - elm_object_style_set(p->r_button, "naviframe/title/default"); + elm_object_style_set(p->r_button, "naviframe/title_icon"); /*elm_object_text_set(p->r_button, _("IDS_EMAIL_OPT_REFRESH"));*/ Evas_Object *ic = elm_icon_add(p->r_button); elm_icon_file_set(ic, TITLE_ICON_REFRESH, NULL); @@ -353,23 +347,30 @@ static void _push_naviframe(struct viewdata *vd) } p->l_button = elm_button_add(vd->ugd->navi_bar); - evas_object_smart_callback_add(p->l_button, "clicked", _back_cb, vd); elm_object_style_set(p->l_button, "naviframe/back_btn/default"); + evas_object_smart_callback_add(p->l_button, "clicked", _back_cb, vd); + + p->tool_btn = elm_button_add(vd->ugd->navi_bar); + elm_object_style_set(p->tool_btn, "naviframe/toolbar/default"); + elm_object_text_set(p->tool_btn, dgettext("sys_string", "IDS_COM_SK_DELETE")); + evas_object_smart_callback_add(p->tool_btn, "clicked", _delete_cb, vd); + account_user_data_t *user_data = (account_user_data_t *)account_data->user_data; Evas_Object *title_ic = elm_icon_add(vd->ugd->navi_bar); evas_object_size_hint_aspect_set(title_ic, EVAS_ASPECT_CONTROL_VERTICAL, 1, 1); elm_icon_resizable_set(title_ic, EINA_TRUE, EINA_TRUE); - elm_icon_file_set(title_ic, account_data->logo_icon_path, NULL); - - account_user_data_t *user_data = (account_user_data_t *)account_data->user_data; + if (user_data->is_preset_account > 0) { + elm_icon_file_set(title_ic, account_data->logo_icon_path, NULL); + } else { + elm_icon_file_set(title_ic, ACCOUNT_ICON_OTHERS, NULL); + } Elm_Object_Item *navi_it = NULL; navi_it = elm_naviframe_item_push(vd->ugd->navi_bar, account_data->account_name, p->l_button, NULL, p->layout, NULL); - if (user_data->is_preset_account > 0) { - elm_object_item_part_content_set(navi_it, "icon", title_ic); - } + elm_object_item_part_content_set(navi_it, "icon", title_ic); + elm_object_item_part_content_set(navi_it, "title_right_btn", p->r_button); - elm_object_item_part_content_set(navi_it, "controlbar", p->cbar); + elm_object_item_part_content_set(navi_it, "toolbar_button1", p->tool_btn); evas_object_show(vd->ugd->navi_bar); p->navi_it = navi_it; } @@ -396,13 +397,13 @@ static void _create_list(struct viewdata *vd) p->genlist = elm_genlist_add(ugd->navi_bar); elm_object_style_set(p->genlist, "dialogue"); - p->itc_account.item_style = "dialogue/2text.1icon.6"; + p->itc_account.item_style = "dialogue/2text.1icon.10"; p->itc_account.func.text_get = _gl_account_text_get_cb; p->itc_account.func.content_get = _gl_account_content_get_cb; p->itc_account.func.state_get = NULL; p->itc_account.func.del = NULL; - p->itc_onoff.item_style = "dialogue/2text.1icon.6"; + p->itc_onoff.item_style = "dialogue/2text.1icon.10"; p->itc_onoff.func.text_get = _gl_onoff_text_get_cb; p->itc_onoff.func.content_get = _gl_onoff_content_get_cb; p->itc_onoff.func.state_get = NULL; @@ -420,7 +421,7 @@ static void _create_list(struct viewdata *vd) p->itc_ex_sync.func.state_get = NULL; p->itc_ex_sync.func.del = NULL; - p->itc_sep.item_style = "dialogue/separator/21/with_line"; + p->itc_sep.item_style = "dialogue/separator"; p->itc_sep.func.text_get = NULL; p->itc_sep.func.content_get = NULL; p->itc_sep.func.state_get = NULL; @@ -465,7 +466,7 @@ static void _create_list(struct viewdata *vd) evas_object_smart_callback_add(p->genlist, "expanded", _gl_exp_cb, (void *)vd); evas_object_smart_callback_add(p->genlist, "contracted", _gl_con_cb, (void *)vd); - elm_object_content_set(p->conform, p->genlist); + elm_object_part_content_set(p->layout, "elm.swallow.content", p->genlist); } static void _update_account_info(struct viewdata *vd) @@ -688,7 +689,7 @@ static void _delete_cb(void *data, Evas_Object *obj, void *event_info) vd->ugd->account_id = account_data->account_id; elm_object_disabled_set(p->l_button, EINA_TRUE); - elm_object_item_disabled_set(p->c_item[0], EINA_TRUE); + elm_object_disabled_set(p->tool_btn, EINA_TRUE); ugd->popup_one = setting_get_notify(vd, NULL, _("IDS_EMAIL_POP_ALL_DATA_RELATED_TO_THIS_ACCOUNT_WILL_BE_DELETED_CONTINUE_Q"), 2, dgettext("sys_string", "IDS_COM_SK_YES"), @@ -794,7 +795,7 @@ static void _popup_cancel_cb(void *data, Evas_Object *obj, void *event_info) } elm_object_disabled_set(p->l_button, EINA_FALSE); - elm_object_item_disabled_set(p->c_item[0], EINA_FALSE); + elm_object_disabled_set(p->tool_btn, EINA_FALSE); } static void _popup_delete_ok_cb(void *data, Evas_Object *obj, void *event_info) @@ -968,7 +969,7 @@ static Evas_Object *_gl_account_content_get_cb(void *data, Evas_Object *obj, con if (!g_strcmp0(part, "elm.icon")) { if (p->syncing) { Evas_Object *pb = elm_progressbar_add(ugd->navi_bar); - elm_object_style_set(pb, "list_process_small"); + elm_object_style_set(pb, "list_process"); elm_progressbar_horizontal_set(pb, EINA_TRUE); elm_progressbar_pulse(pb, EINA_TRUE); return pb; diff --git a/setting/theme/email-setting-theme.edc b/setting/theme/email-setting-theme.edc index 7e4be05..0556598 100755 --- a/setting/theme/email-setting-theme.edc +++ b/setting/theme/email-setting-theme.edc @@ -544,7 +544,7 @@ collections { rel1 { relative: 0.0 0.0;} rel2 { relative: 1.0 1.0;} color: 249 249 249 255; - min: 0 570; + min: 0 600; } } part { @@ -573,8 +573,8 @@ collections { state: "default" 0.0; align: 1.0 0.5; fixed: 0 0; - rel1 { to: "head_rect"; relative: 1 0; offset: -200 10;} - rel2 { to: "head_rect"; relative: 1 1; offset: -10 -10;} + rel1 { to: "head_rect"; relative: 1 0; offset: -220 10;} + rel2 { to: "head_rect"; relative: 1 1; offset: -30 -10;} } } part { @@ -586,8 +586,8 @@ collections { state: "default" 0.0; align: 0.0 0.5; fixed: 0 0; - rel1 { to: "head_rect"; relative: 0 0; offset: 10 10;} - rel2 { to: "head_rect"; relative: 0 1; offset: 200 -10;} + rel1 { to: "head_rect"; relative: 0 0; offset: 30 10;} + rel2 { to: "head_rect"; relative: 0 1; offset: 220 -10;} } } part { @@ -617,8 +617,8 @@ collections { fixed: 1 0; rel1.relative: 0.0 1.0; rel2.relative: 0.0 1.0; - rel1.to: "head_rect"; - rel2.to: "head_rect"; + rel1.to: "bg"; + rel2.to: "bg"; align: 0.0 0.0; } } @@ -629,12 +629,12 @@ collections { description { state: "default" 0.0; visible: 0; - min: 15 0; + min: 20 0; fixed: 1 0; rel1.relative: 1.0 1.0; rel2.relative: 1.0 1.0; - rel1.to: "head_rect"; - rel2.to: "head_rect"; + rel1.to: "bg"; + rel2.to: "bg"; align: 1.0 0.0; } } @@ -644,11 +644,11 @@ collections { scale: 1; description { state: "default" 0.0; - min: 0 174; + min: 0 154; fixed: 0 1; rel1.relative: 0.2 1.0; - rel1.to_y: "top_padding"; rel1.to_x: "bg"; + rel1.to_y: "top_padding"; rel2.relative: 0.8 1.0; rel2.to_x: "bg"; rel2.to_y: "top_padding"; @@ -665,9 +665,11 @@ collections { min: 0 40; fixed: 0 1; rel1.relative: 0.0 1.0; - rel1.to: "color_rect"; + rel1.to_x: "bg"; + rel1.to_y: "color_rect"; rel2.relative: 1.0 1.0; - rel2.to: "color_rect"; + rel2.to_x: "bg"; + rel2.to_y: "color_rect"; align: 0.0 0.0; } } @@ -683,8 +685,8 @@ collections { rel1.to_y: "bottom_padding"; rel2.relative: 0.0 1.0; rel2.to_x: "right_padding"; - rel2.to_y: "bottom_padding"; - align: 0.0 0.0; + rel2.to_y: "bg"; + align: 0.5 0.5; } } }