From: Sangkoo Kim Date: Fri, 26 Oct 2012 04:16:57 +0000 (+0900) Subject: Fix build error. X-Git-Tag: submit/tizen_2.1/20130424.231644~14^2~39 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=5c5b602f59a93b77566d029e40ab86d5d153c8bb;p=platform%2Fcore%2Fmessaging%2Fmsg-service.git Fix build error. Change-Id: I3775eecfd0a0ea300e60e74922c5c782f4b03ed5 --- diff --git a/include/mapi/msg.h b/include/mapi/msg.h index 4497d4d..9731f59 100755 --- a/include/mapi/msg.h +++ b/include/mapi/msg.h @@ -233,6 +233,9 @@ int msg_set_general_opt(msg_handle_t handle, msg_struct_t msg_struct); int msg_get_msgsize_opt(msg_handle_t handle, msg_struct_t msg_struct); int msg_set_msgsize_opt(msg_handle_t handle, msg_struct_t msg_struct); +// text length calculate +int msg_calculate_text_length(msg_handle_t handle, const char* msg_text, msg_encode_type_t msg_encode_type, unsigned int *text_size, unsigned int *segment_size); + #ifdef __cplusplus } #endif diff --git a/mapi/msg_storage.cpp b/mapi/msg_storage.cpp index ee4a065..987ca79 100755 --- a/mapi/msg_storage.cpp +++ b/mapi/msg_storage.cpp @@ -422,6 +422,31 @@ EXPORT_API int msg_get_message(msg_handle_t handle, msg_message_id_t msg_id, msg return err; } +EXPORT_API int msg_get_conversation(msg_handle_t handle, msg_message_id_t msg_id, msg_struct_t conv) +{ + msg_error_t err = MSG_SUCCESS; + + if (handle == NULL || !conv) + { + MSG_FATAL("handle or opq_msg is NULL"); + return -EINVAL; + } + + MsgHandle* pHandle = (MsgHandle*)handle; + + msg_struct_s *pMsgStruct = (msg_struct_s *)conv; + try + { + err = pHandle->getConversationViewItem(msg_id, (MSG_CONVERSATION_VIEW_S *)pMsgStruct->data); + } + catch (MsgException& e) + { + MSG_FATAL("%s", e.what()); + return MSG_ERR_STORAGE_ERROR; + } + + return err; +} EXPORT_API int msg_get_folder_view_list(msg_handle_t handle, msg_folder_id_t folder_id, const msg_struct_t sort_rule, msg_struct_list_s *msg_folder_view_list) {