static Ecore_Event_Handler *_event_handlers[EVENT_HANDLER_MAX];
static mmi_client *g_client = NULL;
-static void output_result_received_cb(const char *app_id, const char *json_data, void *user_data)
+static void __output_result_received_cb(const char *app_id, const char *json_data, void *user_data)
{
// TODO: implement
}
-static void output_modality_received_cb(const char *app_id, int type, void *event, void *user_data)
+static void __output_modality_received_cb(const char *app_id, int type, void *event, void *user_data)
{
if (type == MMI_PROVIDER_EVENT_KEY) {
mmi_provider_event_key *key_event = (mmi_provider_event_key *)event;
}
}
-static Eina_Bool _focus_change_cb(void *data EINA_UNUSED, int type, void *event)
+static Eina_Bool __focus_change_cb(void *data EINA_UNUSED, int type, void *event)
{
mmi_manager_event_focus_change *ev = (mmi_manager_event_focus_change *)event;
_I("[focus change] cur focus : %p, new focus : %p", ev->cur_focus, ev->new_focus);
return ECORE_CALLBACK_PASS_ON;
}
-static Eina_Bool _state_change_cb(void *data EINA_UNUSED, int type, void *event)
+static Eina_Bool __state_change_cb(void *data EINA_UNUSED, int type, void *event)
{
mmi_manager_event_state_change *ev = (mmi_manager_event_state_change *)event;
g_client = ev->client;
return ECORE_CALLBACK_PASS_ON;
}
-static Eina_Bool _key_event_cb(void *data EINA_UNUSED, int type, void *event)
+static Eina_Bool __key_event_cb(void *data EINA_UNUSED, int type, void *event)
{
mmi_provider_event_key *ev = (mmi_provider_event_key *)event;
_I("[key event] code : %d, name : %s, type : %d, timestamp : %d, source: %s", ev->keycode, ev->keyname, ev->type, ev->timestamp, ev->source);
return ECORE_CALLBACK_PASS_ON;
}
-static Eina_Bool _gesture_event_cb(void *data EINA_UNUSED, int type, void *event)
+static Eina_Bool __gesture_event_cb(void *data EINA_UNUSED, int type, void *event)
{
mmi_provider_event_gesture *ev = (mmi_provider_event_gesture *)event;
_I("[gesture event] type : %d, timestamp : %d", ev->type, ev->timestamp);
return ECORE_CALLBACK_PASS_ON;
}
-static Eina_Bool _voice_event_cb(void *data EINA_UNUSED, int type, void *event)
+static Eina_Bool __voice_event_cb(void *data EINA_UNUSED, int type, void *event)
{
mmi_provider_event_voice *ev = (mmi_provider_event_voice *)event;
_I("[voice event] type : %d, timestamp : %d", ev->type, ev->timestamp);
return ECORE_CALLBACK_PASS_ON;
}
-static Eina_Bool _vision_event_cb(void *data EINA_UNUSED, int type, void *event)
+static Eina_Bool __vision_event_cb(void *data EINA_UNUSED, int type, void *event)
{
mmi_provider_event_vision *ev = (mmi_provider_event_vision *)event;
return ECORE_CALLBACK_PASS_ON;
}
-static Eina_Bool _screen_analyzer_event_cb(void *data EINA_UNUSED, int type, void *event)
+static Eina_Bool __screen_analyzer_event_cb(void *data EINA_UNUSED, int type, void *event)
{
mmi_provider_event_screen_analyzer *ev = (mmi_provider_event_screen_analyzer *)event;
_I("[Screen analyzer] Number of items : %d, type : %d, timestamp : %d", ev->n_items, ev->type, ev->timestamp);
return ECORE_CALLBACK_PASS_ON;
}
-static void shutdown_event_handler()
+static void __shutdown_event_handler()
{
_I("Shutdown event handlers");
for (int i = 0; i < EVENT_HANDLER_MAX; i++) {
}
}
-static void init_event_handler()
+static void __init_event_handler()
{
_I("Initialize event handlers");
_event_handlers[EVENT_HANDLER_FOCUS_CHANGE] = ecore_event_handler_add(MMI_MANAGER_EVENT_FOCUS_CHANGE,
- _focus_change_cb, NULL);
+ __focus_change_cb, NULL);
_event_handlers[EVENT_HANDLER_STATE_CHANGE] = ecore_event_handler_add(MMI_MANAGER_EVENT_STATE_CHANGE,
- _state_change_cb, NULL);
+ __state_change_cb, NULL);
_event_handlers[EVENT_HANDLER_KEY] = ecore_event_handler_add(MMI_PROVIDER_EVENT_KEY,
- _key_event_cb, NULL);
+ __key_event_cb, NULL);
_event_handlers[EVENT_HANDLER_GESTURE] = ecore_event_handler_add(MMI_PROVIDER_EVENT_GESTURE,
- _gesture_event_cb, NULL);
+ __gesture_event_cb, NULL);
_event_handlers[EVENT_HANDLER_VOICE] = ecore_event_handler_add(MMI_PROVIDER_EVENT_VOICE,
- _voice_event_cb, NULL);
+ __voice_event_cb, NULL);
_event_handlers[EVENT_HANDLER_VISION] = ecore_event_handler_add(MMI_PROVIDER_EVENT_VISION,
- _vision_event_cb, NULL);
+ __vision_event_cb, NULL);
_event_handlers[EVENT_HANDLER_SCREEN_ANALYZER] = ecore_event_handler_add(MMI_PROVIDER_EVENT_SCREEN_ANALYZER,
- _screen_analyzer_event_cb, NULL);
+ __screen_analyzer_event_cb, NULL);
}
int mmi_core_init()
return ret;
}
- init_event_handler();
+ __init_event_handler();
- ret = mmi_iu_set_output_intent_received_callback(output_result_received_cb, NULL);
+ ret = mmi_iu_set_output_intent_received_callback(__output_result_received_cb, NULL);
if (ret != MMI_IU_ERROR_NONE) {
_E("Error code : %d", ret);
return ret;
}
- ret = mmi_iu_set_output_event_received_callback(output_modality_received_cb, NULL);
+ ret = mmi_iu_set_output_event_received_callback(__output_modality_received_cb, NULL);
if (ret != MMI_IU_ERROR_NONE) {
_E("Error code : %d", ret);
return ret;
int mmi_core_shutdown()
{
_I("Shutdown MMI core module");
- shutdown_event_handler();
+ __shutdown_event_handler();
int ret = mmi_iu_shutdown();
return ret;