From: Igor Olshevskyi Date: Mon, 18 Jan 2016 09:24:07 +0000 (+0200) Subject: TizenRefApp-5506 [Call UI] Fix build for 64-bit architecture X-Git-Tag: accepted/tizen/mobile/20160122.030421~2 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=09e07cdf05264b67b1e3803b20998fe73a4f5295;p=profile%2Fmobile%2Fapps%2Fnative%2Fcall-ui.git TizenRefApp-5506 [Call UI] Fix build for 64-bit architecture Change-Id: If7e47d4e996f0dc836453c1d5381a5596966d830 --- diff --git a/src/callui-view-incoming-lock.c b/src/callui-view-incoming-lock.c index 4a7dd8a..af8d602 100755 --- a/src/callui-view-incoming-lock.c +++ b/src/callui-view-incoming-lock.c @@ -35,6 +35,8 @@ #define CALLUI_CST_REJECT_MSG_GET "cst_reject_msg_get" #define REJ_MSG_GENLIST_DATA "reject_msg_genlist_data" +#define SAVE_C_CAST(type, value) ((type)(ptrdiff_t)value) + static int __callui_view_incoming_lock_oncreate(call_view_data_t *view_data, unsigned int param1, void *param2, void *appdata); static int __callui_view_incoming_lock_onupdate(call_view_data_t *view_data, void *update_data1); static int __callui_view_incoming_lock_onhide(call_view_data_t *view_data); @@ -261,7 +263,7 @@ static char *__callui_view_incoming_lock_reject_msg_gl_label_get_msg(void *data, call_view_data_t *vd = (call_view_data_t *)evas_object_data_get(obj, REJ_MSG_GENLIST_DATA); CALLUI_RETURN_VALUE_IF_FAIL(vd, NULL); - int index = (int)data; + int index = SAVE_C_CAST(int, data); char *msg_str = NULL; if (!strcmp(part, "elm.text")) { @@ -281,7 +283,7 @@ static char *__callui_view_incoming_lock_reject_msg_gl_label_get_msg(void *data, static void __reject_msg_gl_sel_msg(void *data, Evas_Object *obj, void *event_info) { dbg(".."); - int index = (int)data; + int index = SAVE_C_CAST(int, data); int ret = -1; dbg("index: %d", index); callui_app_data_t *ad = _callui_get_app_data(); @@ -322,7 +324,9 @@ static void __reject_msg_gl_sel_msg(void *data, Evas_Object *obj, void *event_in Elm_Object_Item *_callui_view_incoming_lock_append_genlist_item(Evas_Object *msg_glist, Elm_Genlist_Item_Class * itc_reject_msg, int index) { Elm_Object_Item *item = NULL; - item = elm_genlist_item_append(msg_glist, itc_reject_msg, (void *)index, NULL, ELM_GENLIST_ITEM_NONE, __reject_msg_gl_sel_msg, (void *)index); + item = elm_genlist_item_append(msg_glist, itc_reject_msg, + SAVE_C_CAST(void *, index), NULL, ELM_GENLIST_ITEM_NONE, + __reject_msg_gl_sel_msg, SAVE_C_CAST(void *, index)); return item; }