static E_DBus_Connection *edbus_conn = NULL;
-/* Terminate popup */
+/* Terminate window */
static Eina_Bool exit_idler_cb(void *data)
{
elm_exit();
return ECORE_CALLBACK_CANCEL;
}
-void popup_terminate(void)
+void window_terminate(void)
{
if (ecore_idler_add(exit_idler_cb, NULL))
return;
ret = feedback_initialize();
if (ret != FEEDBACK_ERROR_NONE) {
- _E("Cannot initialize feedback");
+ _E("Cannot initialize feedback.");
return;
}
ret = feedback_play(pattern);
break;
default:
- _E("Play type is unknown");
+ _E("Play type is unknown.");
ret = 0;
}
if (ret != FEEDBACK_ERROR_NONE)
- _E("Cannot play feedback: %d", pattern);
+ _E("Cannot play feedback(%d).", pattern);
ret = feedback_deinitialize();
if (ret != FEEDBACK_ERROR_NONE)
- _E("Cannot deinitialize feedback");
+ _E("Cannot deinitialize feedback.");
+}
+
+void init_multi_feedback(void)
+{
+ int ret;
+
+ ret = feedback_initialize();
+ if (ret != FEEDBACK_ERROR_NONE)
+ _E("Cannot initialize feedback.");
+}
+
+void play_multi_feedback(int pattern)
+{
+ int ret;
+
+ ret = feedback_play(pattern);
+ if (ret != FEEDBACK_ERROR_NONE)
+ _E("Cannot play feedback(%d).", pattern);
+}
+
+void stop_multi_feedback(void)
+{
+ int ret;
+
+ ret = feedback_deinitialize();
+ if (ret != FEEDBACK_ERROR_NONE)
+ _E("Cannot deinitialize feedback.");
}
static void *thread_feedback(void* data)
static void *thread_display(void* data)
{
if (display_change_state(LCD_NORMAL) < 0)
- _E("FAIL: display_change_state()");
+ _E("Failed to display_change_state().");
return NULL;
}
ret = pthread_create(&th, NULL, operation, data);
if (ret < 0) {
- _E("Failed to create pthread(%d)", ret);
+ _E("Failed to create pthread: %d", ret);
return;
}
pthread_detach(th);
edbus_conn = e_dbus_bus_get(DBUS_BUS_SYSTEM);
if (!edbus_conn) {
- _E("Failed to get dbus bus");
+ _E("Failed to get dbus bus.");
e_dbus_shutdown();
return -ENOMEM;
}
conn = get_dbus_connection();
if (!conn) {
- _E("Failed to get dbus connection");
+ _E("Failed to get dbus connection.");
return -ENOMEM;
}
msg = dbus_message_new_signal(path, interface, name);
if (!msg) {
- _E("FAIL: dbus_message_new_signal()");
+ _E("Failed to dbus_message_new_signal().");
return -ENOMEM;
}
dbus_message_iter_init_append(msg, &iter);
ret = append_variant(&iter, sig, param);
if (ret < 0) {
- _E("append_variant error(%d)", ret);
+ _E("Failed to append_variant: %d", ret);
goto out;
}
pc = e_dbus_message_send(conn, msg, NULL, -1, NULL);
if (!pc) {
- _E("FAIL: e_dbus_message_send()");
+ _E("Failed to e_dbus_message_send().");
ret = -ECONNREFUSED;
goto out;
}
conn = dbus_bus_get(DBUS_BUS_SYSTEM, NULL);
if (!conn) {
- _E("dbus_bus_get error");
+ _E("Failed to dbus_bus_get.");
return -EPERM;
}
msg = dbus_message_new_method_call(dest, path, interface, method);
if (!msg) {
- _E("dbus_message_new_method_call(%s:%s-%s)",
+ _E("dbus_message_new_method_call(%s:%s-%s).",
path, interface, method);
ret = -EBADMSG;
goto out;
dbus_message_iter_init_append(msg, &iter);
ret = append_variant(&iter, sig, param);
if (ret < 0) {
- _E("append_variant error(%d)", ret);
+ _E("Failed to append_variant: %d", ret);
goto out;
}
ret = dbus_message_get_args(reply, &err,
DBUS_TYPE_INT32, &result, DBUS_TYPE_INVALID);
if (!ret) {
- _E("no message : [%s:%s]", err.name, err.message);
+ _E("No message. err.name=%s: %s", err.name, err.message);
dbus_error_free(&err);
ret = -ENOMSG;
goto out;
conn = get_dbus_connection();
if (!conn) {
- _E("Failed to get dbus connection");
+ _E("Failed to get dbus connection.");
return;
}
conn = get_dbus_connection();
if (!conn) {
- _E("Failed to get dbus connection");
+ _E("Failed to get dbus connection.");
return -ENOMEM;
}