Fix build error.
authorSangkoo Kim <sangkoo.kim@samsung.com>
Fri, 26 Oct 2012 04:16:57 +0000 (13:16 +0900)
committerSangkoo Kim <sangkoo.kim@samsung.com>
Fri, 26 Oct 2012 04:16:57 +0000 (13:16 +0900)
Change-Id: I3775eecfd0a0ea300e60e74922c5c782f4b03ed5

include/mapi/msg.h
mapi/msg_storage.cpp

index 4497d4d..9731f59 100755 (executable)
@@ -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
index ee4a065..987ca79 100755 (executable)
@@ -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)
 {