fix code 33/156133/1
authorjomui <jongmun.woo@samsung.com>
Tue, 17 Oct 2017 07:58:57 +0000 (16:58 +0900)
committerjomui <jongmun.woo@samsung.com>
Tue, 17 Oct 2017 07:59:25 +0000 (16:59 +0900)
Signed-off-by: jomui <jongmun.woo@samsung.com>
Change-Id: Ic46fc19ac0b3dbbea12ef5f64f0528a1ea96af5c

heremaps-uc/src/heremaps-uc.c

index 70ecac5..a10dae1 100644 (file)
@@ -23,8 +23,6 @@
 #include <stdlib.h>
 #include <system_info.h>
 
-#define EDJE_PATH "/usr/apps/org.tizen.heremaps-uc/res/edje/heremaps-uc.edj"
-
 typedef enum {
        TIZEN_PROFILE_UNKNOWN = 0,
        TIZEN_PROFILE_MOBILE = 0x1,
@@ -190,11 +188,9 @@ static void anchor_clicked_cb(void *data, Evas_Object *obj, void *event_info)
 static Evas_Object *create_popup_tv(Evas_Object *layout, heremaps_uc_app_data *ad)
 {
        LS_FUNC_ENTER
-       Evas_Object *popup;
-       Evas_Object *disagree_btn, *agree_btn;
 
        /* popup */
-       popup = elm_popup_add(layout);
+       Evas_Object *popup = elm_popup_add(layout);
        eext_object_event_callback_add(popup, EEXT_CALLBACK_BACK, back_btn_cb, ad);
        evas_object_size_hint_weight_set(popup, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
        elm_object_part_text_set(popup, "title,text", P_("IDS_POSITIONING_CONSENT_TITLE"));
@@ -211,7 +207,7 @@ static Evas_Object *create_popup_tv(Evas_Object *layout, heremaps_uc_app_data *a
        snprintf(buf, 4096, str1, str2, str3);
        char *text = strdup(buf);
 
-       Evas_Objectentry = elm_entry_add(box);
+       Evas_Object *entry = elm_entry_add(box);
        evas_object_size_hint_weight_set(entry, EVAS_HINT_EXPAND, 0.0);
        evas_object_size_hint_align_set(entry, EVAS_HINT_FILL, EVAS_HINT_FILL);
        elm_entry_editable_set(entry, EINA_FALSE);
@@ -221,20 +217,21 @@ static Evas_Object *create_popup_tv(Evas_Object *layout, heremaps_uc_app_data *a
        evas_object_show(entry);
 
        /* Disagree button */
-       disagree_btn = elm_button_add(popup);
+       Evas_Object *disagree_btn = elm_button_add(popup);
        elm_object_style_set(disagree_btn, "popup");
        elm_object_text_set(disagree_btn, P_("IDS_ST_BUTTON_DISAGREE"));
        elm_object_part_content_set(popup, "button1", disagree_btn);
        evas_object_smart_callback_add(disagree_btn, "clicked", disagree_btn_cb, ad);
 
        /* Agree button */
-       agree_btn = elm_button_add(popup);
+       Evas_Object *agree_btn = elm_button_add(popup);
        elm_object_style_set(agree_btn, "popup");
        elm_object_text_set(agree_btn, P_("IDS_ST_BUTTON_AGREE"));
        elm_object_part_content_set(popup, "button2", agree_btn);
        evas_object_smart_callback_add(agree_btn, "clicked", agree_btn_cb, ad);
 
        evas_object_show(popup);
+
        LS_FUNC_EXIT
        return popup;
 }
@@ -242,11 +239,9 @@ static Evas_Object *create_popup_tv(Evas_Object *layout, heremaps_uc_app_data *a
 static Evas_Object *create_popup_wearable(Evas_Object *layout, heremaps_uc_app_data *ad)
 {
        LS_FUNC_ENTER
-       Evas_Object *popup;
-       Evas_Object *agree_btn;
 
        /* popup */
-       popup = elm_popup_add(layout);
+       Evas_Object *popup = elm_popup_add(layout);
        elm_object_style_set(popup, "circle");
        evas_object_size_hint_weight_set(popup, EVAS_HINT_FILL, EVAS_HINT_FILL);
        eext_object_event_callback_add(popup, EEXT_CALLBACK_BACK, back_btn_cb, ad);
@@ -270,7 +265,7 @@ static Evas_Object *create_popup_wearable(Evas_Object *layout, heremaps_uc_app_d
        snprintf(buf, 4096, str1, str2, str3);
        char *text = strdup(buf);
 
-       Evas_Objectentry = elm_entry_add(box);
+       Evas_Object *entry = elm_entry_add(box);
        evas_object_size_hint_weight_set(entry, EVAS_HINT_EXPAND, 0.0);
        evas_object_size_hint_align_set(entry, EVAS_HINT_FILL, EVAS_HINT_FILL);
        elm_entry_editable_set(entry, EINA_FALSE);
@@ -280,7 +275,7 @@ static Evas_Object *create_popup_wearable(Evas_Object *layout, heremaps_uc_app_d
        evas_object_show(entry);
 
        /* Agree button */
-       agree_btn = elm_button_add(popup);
+       Evas_Object *agree_btn = elm_button_add(popup);
        elm_object_style_set(agree_btn, "popup/circle");
        evas_object_size_hint_weight_set(agree_btn, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
        elm_object_part_text_set(agree_btn, "elm.text", P_("IDS_ST_BUTTON_AGREE"));
@@ -289,6 +284,7 @@ static Evas_Object *create_popup_wearable(Evas_Object *layout, heremaps_uc_app_d
        elm_object_part_content_set(popup, "button1", agree_btn);
 
        evas_object_show(popup);
+
        LS_FUNC_EXIT
        return popup;
 }
@@ -296,11 +292,9 @@ static Evas_Object *create_popup_wearable(Evas_Object *layout, heremaps_uc_app_d
 static Evas_Object *create_popup(Evas_Object *layout, heremaps_uc_app_data *ad)
 {
        LS_FUNC_ENTER
-       Evas_Object *popup;
-       Evas_Object *disagree_btn, *agree_btn;
 
        /* popup */
-       popup = elm_popup_add(layout);
+       Evas_Object *popup = elm_popup_add(layout);
        elm_popup_align_set(popup, ELM_NOTIFY_ALIGN_FILL, 1.0);
        eext_object_event_callback_add(popup, EEXT_CALLBACK_BACK, back_btn_cb, ad);
        evas_object_size_hint_weight_set(popup, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
@@ -318,7 +312,7 @@ static Evas_Object *create_popup(Evas_Object *layout, heremaps_uc_app_data *ad)
        snprintf(buf, 4096, str1, str2, str3);
        char *text = strdup(buf);
 
-       Evas_Objectentry = elm_entry_add(box);
+       Evas_Object *entry = elm_entry_add(box);
        evas_object_size_hint_weight_set(entry, EVAS_HINT_EXPAND, 0.0);
        evas_object_size_hint_align_set(entry, EVAS_HINT_FILL, EVAS_HINT_FILL);
        elm_entry_editable_set(entry, EINA_FALSE);
@@ -329,20 +323,21 @@ static Evas_Object *create_popup(Evas_Object *layout, heremaps_uc_app_data *ad)
        evas_object_show(entry);
 
        /* Disagree button */
-       disagree_btn = elm_button_add(popup);
+       Evas_Object *disagree_btn = elm_button_add(popup);
        elm_object_style_set(disagree_btn, "popup");
        elm_object_text_set(disagree_btn, P_("IDS_ST_BUTTON_DISAGREE"));
        elm_object_part_content_set(popup, "button1", disagree_btn);
        evas_object_smart_callback_add(disagree_btn, "clicked", disagree_btn_cb, ad);
 
        /* Agree button */
-       agree_btn = elm_button_add(popup);
+       Evas_Object *agree_btn = elm_button_add(popup);
        elm_object_style_set(agree_btn, "popup");
        elm_object_text_set(agree_btn, P_("IDS_ST_BUTTON_AGREE"));
        elm_object_part_content_set(popup, "button2", agree_btn);
        evas_object_smart_callback_add(agree_btn, "clicked", agree_btn_cb, ad);
 
        evas_object_show(popup);
+
        LS_FUNC_EXIT
        return popup;
 }