From: Suyeon Hwang Date: Wed, 29 Sep 2021 02:26:42 +0000 (+0900) Subject: Make ipc method name more specific X-Git-Tag: submit/tizen/20210929.093305~3 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=969d0f1df01f4989406696189d41a53ab96a4095;p=platform%2Fcore%2Fuifw%2Ftts.git Make ipc method name more specific Change-Id: Iff46d2653dbadfe8ed5de389166020912aaed2e3 Signed-off-by: Suyeon Hwang --- diff --git a/server/ttsd_ipc.c b/server/ttsd_ipc.c index fdefe60c..cf774141 100644 --- a/server/ttsd_ipc.c +++ b/server/ttsd_ipc.c @@ -17,10 +17,10 @@ #include "ttsd_data.h" -int(*ttsd_dbus_vtable[])() = {&ttsd_dbus_open_connection, &ttsd_dbus_close_connection, - &ttsdc_dbus_send_utt_start_message, &ttsdc_dbus_send_error_message}; -int(*ttsd_tidl_vtable[])() = {&ttsd_tidl_open_connection, &ttsd_tidl_close_connection, - &ttsdc_tidl_send_message, &ttsdc_tidl_send_error_message}; +int(*ttsd_dbus_vtable[])() = {&ttsd_dbus_open_connection, &ttsd_dbus_close_connection, &ttsdc_dbus_send_utt_start_message, + &ttsdc_dbus_send_utt_finish_message, &ttsdc_dbus_send_set_state_message, &ttsdc_dbus_send_error_message}; +int(*ttsd_tidl_vtable[])() = {&ttsd_tidl_open_connection, &ttsd_tidl_close_connection, &ttsdc_tidl_send_message, + &ttsdc_tidl_send_message, &ttsdc_tidl_send_message, &ttsdc_tidl_send_error_message}; int ttsd_ipc_open_connection() { @@ -69,11 +69,11 @@ int ttsdc_ipc_send_utt_start_message(int pid, int uid, int uttid) { case TTS_IPC_METHOD_DBUS: SLOG(LOG_DEBUG, tts_tag(), "[IPC] ipc method : dbus"); - return ttsd_dbus_vtable[SEND_MESSAGE](pid, uid, uttid, TTSD_METHOD_UTTERANCE_STARTED); + return ttsd_dbus_vtable[SEND_UTTERANCE_START](pid, uid, uttid); case TTS_IPC_METHOD_TIDL: SLOG(LOG_DEBUG, tts_tag(), "[IPC] ipc method : tidl"); - return ttsd_tidl_vtable[SEND_MESSAGE](pid, uid, uttid, TTSD_METHOD_UTTERANCE_STARTED); + return ttsd_tidl_vtable[SEND_UTTERANCE_START](pid, uid, uttid, TTSD_METHOD_UTTERANCE_STARTED); default: SLOG(LOG_ERROR, tts_tag(), "[ERROR] method is not valid"); @@ -95,11 +95,11 @@ int ttsdc_ipc_send_utt_finish_message(int pid, int uid, int uttid) { case TTS_IPC_METHOD_DBUS: SLOG(LOG_DEBUG, tts_tag(), "[IPC] ipc method : dbus"); - return ttsd_dbus_vtable[SEND_MESSAGE](pid, uid, uttid, TTSD_METHOD_UTTERANCE_COMPLETED); + return ttsd_dbus_vtable[SEND_UTTERANCE_FINISH](pid, uid, uttid); case TTS_IPC_METHOD_TIDL: SLOG(LOG_DEBUG, tts_tag(), "[IPC] ipc method : tidl"); - return ttsd_tidl_vtable[SEND_MESSAGE](pid, uid, uttid, TTSD_METHOD_UTTERANCE_COMPLETED); + return ttsd_tidl_vtable[SEND_UTTERANCE_FINISH](pid, uid, uttid, TTSD_METHOD_UTTERANCE_COMPLETED); default: SLOG(LOG_ERROR, tts_tag(), "[ERROR] method is not valid"); @@ -121,11 +121,11 @@ int ttsdc_ipc_send_set_state_message(int pid, int uid, int state) { case TTS_IPC_METHOD_DBUS: SLOG(LOG_DEBUG, tts_tag(), "[IPC] ipc method : dbus"); - return ttsd_dbus_vtable[SEND_MESSAGE](pid, uid, state, TTSD_METHOD_SET_STATE); + return ttsd_dbus_vtable[SEND_SET_STATE](pid, uid, state); case TTS_IPC_METHOD_TIDL: SLOG(LOG_DEBUG, tts_tag(), "[IPC] ipc method : tidl"); - return ttsd_tidl_vtable[SEND_MESSAGE] (pid, uid, state, TTSD_METHOD_SET_STATE); + return ttsd_tidl_vtable[SEND_SET_STATE] (pid, uid, state, TTSD_METHOD_SET_STATE); default: SLOG(LOG_ERROR, tts_tag(), "[ERROR] method is not valid"); diff --git a/server/ttsd_ipc.h b/server/ttsd_ipc.h index af4afc11..878cfd6a 100644 --- a/server/ttsd_ipc.h +++ b/server/ttsd_ipc.h @@ -24,7 +24,9 @@ extern "C" { typedef enum { OPEN_CONNECTION, CLOSE_CONNECTION, - SEND_MESSAGE, + SEND_UTTERANCE_START, + SEND_UTTERANCE_FINISH, + SEND_SET_STATE, SEND_ERROR } ttsd_ipc_vtable_e;