aboutsummaryrefslogtreecommitdiffstats
path: root/src/bin
diff options
context:
space:
mode:
authorLucas De Marchi <lucas.demarchi@profusion.mobi>2013-04-23 12:08:29 -0300
committerLucas De Marchi <lucas.demarchi@profusion.mobi>2013-04-23 12:37:43 -0300
commitf8a2dd4d959f420ba1fddeea4c727e008240af46 (patch)
tree8baf7293e123873604b2c80b7c39c7f19c21f8e8 /src/bin
parentignore window focus in events on iconic borders; these are guaranteed to be w... (diff)
downloadenlightenment-f8a2dd4d959f420ba1fddeea4c727e008240af46.tar.gz
Rename edbus->eldbus
Diffstat (limited to 'src/bin')
-rw-r--r--src/bin/e.h2
-rw-r--r--src/bin/e_dbusmenu.c148
-rw-r--r--src/bin/e_dbusmenu.h4
-rw-r--r--src/bin/e_fm/e_fm_main.c2
-rw-r--r--src/bin/e_fm/e_fm_main_udisks.c336
-rw-r--r--src/bin/e_fm_cmdline.c26
-rw-r--r--src/bin/e_fm_shared_types.h.in8
-rw-r--r--src/bin/e_msgbus.c336
-rw-r--r--src/bin/e_msgbus.h8
-rw-r--r--src/bin/e_notification.c200
-rw-r--r--src/bin/e_notification.h2
11 files changed, 536 insertions, 536 deletions
diff --git a/src/bin/e.h b/src/bin/e.h
index 314cd326e..4ecc03c33 100644
--- a/src/bin/e.h
+++ b/src/bin/e.h
@@ -114,7 +114,7 @@ void *alloca (size_t);
# include <Efreet.h>
# include <Efreet_Mime.h>
# include <Edje.h>
-# include <EDBus.h>
+# include <Eldbus.h>
# include <Eio.h>
# ifdef HAVE_HAL
diff --git a/src/bin/e_dbusmenu.c b/src/bin/e_dbusmenu.c
index c8dbcbd4e..c186ee953 100644
--- a/src/bin/e_dbusmenu.c
+++ b/src/bin/e_dbusmenu.c
@@ -4,7 +4,7 @@
struct _E_DBusMenu_Ctx
{
- EDBus_Proxy *proxy;
+ Eldbus_Proxy *proxy;
E_DBusMenu_Item *root_menu;
void *data;
E_DBusMenu_Pop_Request_Cb pop_request_cb;
@@ -45,7 +45,7 @@ id_find(const char *text, const char *array_of_names[], unsigned max)
}
static void
-dbus_menu_prop_dict_cb(void *data, const void *key, EDBus_Message_Iter *var)
+dbus_menu_prop_dict_cb(void *data, const void *key, Eldbus_Message_Iter *var)
{
E_DBusMenu_Item *m = data;
if (!strcmp(key, "label"))
@@ -54,7 +54,7 @@ dbus_menu_prop_dict_cb(void *data, const void *key, EDBus_Message_Iter *var)
Eina_Strbuf *label_buf = eina_strbuf_new();
int i;
- edbus_message_iter_arguments_get(var, "s", &label);
+ eldbus_message_iter_arguments_get(var, "s", &label);
for (i = 0; label[i]; i++)
{
if (label[i] != '_')
@@ -76,17 +76,17 @@ dbus_menu_prop_dict_cb(void *data, const void *key, EDBus_Message_Iter *var)
else if (!strcmp(key, "type"))
{
const char *type;
- edbus_message_iter_arguments_get(var, "s", &type);
+ eldbus_message_iter_arguments_get(var, "s", &type);
m->type = id_find(type, Menu_Item_Type_Names, E_DBUSMENU_ITEM_TYPE_LAST);
}
else if (!strcmp(key, "icon-data"))
{
- EDBus_Message_Iter *array;
+ Eldbus_Message_Iter *array;
int size;
const unsigned char *img_data;
- edbus_message_iter_arguments_get(var, "ay", &array);
- edbus_message_iter_fixed_array_get(array, 'y', &img_data, &size);
+ eldbus_message_iter_arguments_get(var, "ay", &array);
+ eldbus_message_iter_fixed_array_get(array, 'y', &img_data, &size);
if (!size)
return;
m->icon_data = malloc(sizeof(unsigned char) * size);
@@ -97,20 +97,20 @@ dbus_menu_prop_dict_cb(void *data, const void *key, EDBus_Message_Iter *var)
else if (!strcmp(key, "icon-name"))
{
const char *icon_name;
- edbus_message_iter_arguments_get(var, "s", &icon_name);
+ eldbus_message_iter_arguments_get(var, "s", &icon_name);
eina_stringshare_replace(&m->icon_name, icon_name);
}
else if (!strcmp(key, "toggle-type"))
{
const char *toggle_type;
- edbus_message_iter_arguments_get(var, "s", &toggle_type);
+ eldbus_message_iter_arguments_get(var, "s", &toggle_type);
m->toggle_type = id_find(toggle_type, Menu_Item_Toggle_Type_Names,
E_DBUSMENU_ITEM_TOGGLE_TYPE_LAST);
}
else if (!strcmp(key, "toggle-state"))
{
int state;
- edbus_message_iter_arguments_get(var, "i", &state);
+ eldbus_message_iter_arguments_get(var, "i", &state);
if (state == 1)
m->toggle_state = EINA_TRUE;
else
@@ -119,7 +119,7 @@ dbus_menu_prop_dict_cb(void *data, const void *key, EDBus_Message_Iter *var)
else if (!strcmp(key, "children-display"))
{
const char *display;
- edbus_message_iter_arguments_get(var, "s", &display);
+ eldbus_message_iter_arguments_get(var, "s", &display);
if (!strcmp(display, "submenu"))
m->is_submenu = EINA_TRUE;
else
@@ -128,27 +128,27 @@ dbus_menu_prop_dict_cb(void *data, const void *key, EDBus_Message_Iter *var)
else if (!strcmp(key, "disposition"))
{
const char *disposition;
- edbus_message_iter_arguments_get(var, "s", &disposition);
+ eldbus_message_iter_arguments_get(var, "s", &disposition);
m->disposition = id_find(disposition, Menu_Item_Dispostion_Names,
E_DBUSMENU_ITEM_DISPOSTION_LAST);
}
else if (!strcmp(key, "enabled"))
- edbus_message_iter_arguments_get(var, "b", &m->enabled);
+ eldbus_message_iter_arguments_get(var, "b", &m->enabled);
else if (!strcmp(key, "visible"))
- edbus_message_iter_arguments_get(var, "b", &m->visible);
+ eldbus_message_iter_arguments_get(var, "b", &m->visible);
}
static E_DBusMenu_Item *
-parse_layout(EDBus_Message_Iter *layout, E_DBusMenu_Item *parent, E_DBusMenu_Ctx *ctx)
+parse_layout(Eldbus_Message_Iter *layout, E_DBusMenu_Item *parent, E_DBusMenu_Ctx *ctx)
{
- EDBus_Message_Iter *menu_item_prop, *sub_menu_items_prop, *var;
+ Eldbus_Message_Iter *menu_item_prop, *sub_menu_items_prop, *var;
E_DBusMenu_Item *m = calloc(1, sizeof(E_DBusMenu_Item));
EINA_SAFETY_ON_NULL_RETURN_VAL(m, NULL);
m->ctx = ctx;
m->enabled = EINA_TRUE;
m->visible = EINA_TRUE;
- if (!edbus_message_iter_arguments_get(layout, "ia{sv}av", &m->id,
+ if (!eldbus_message_iter_arguments_get(layout, "ia{sv}av", &m->id,
&menu_item_prop, &sub_menu_items_prop))
{
ERR("Error reading message");
@@ -156,12 +156,12 @@ parse_layout(EDBus_Message_Iter *layout, E_DBusMenu_Item *parent, E_DBusMenu_Ctx
return NULL;
}
- edbus_message_iter_dict_iterate(menu_item_prop, "sv", dbus_menu_prop_dict_cb, m);
+ eldbus_message_iter_dict_iterate(menu_item_prop, "sv", dbus_menu_prop_dict_cb, m);
- while (edbus_message_iter_get_and_next(sub_menu_items_prop, 'v', &var))
+ while (eldbus_message_iter_get_and_next(sub_menu_items_prop, 'v', &var))
{
- EDBus_Message_Iter *st;
- if (!edbus_message_iter_arguments_get(var, "(ia{sv}av)", &st))
+ Eldbus_Message_Iter *st;
+ if (!eldbus_message_iter_arguments_get(var, "(ia{sv}av)", &st))
{
ERR("Error readding message.");
continue;
@@ -198,21 +198,21 @@ dbus_menu_free(E_DBusMenu_Item *m)
}
static void
-layout_get_cb(void *data, const EDBus_Message *msg, EDBus_Pending *pending EINA_UNUSED)
+layout_get_cb(void *data, const Eldbus_Message *msg, Eldbus_Pending *pending EINA_UNUSED)
{
E_DBusMenu_Item *m;
const char *error, *error_msg;
- EDBus_Message_Iter *layout;
+ Eldbus_Message_Iter *layout;
unsigned revision;
E_DBusMenu_Ctx *ctx = data;
- if (edbus_message_error_get(msg, &error, &error_msg))
+ if (eldbus_message_error_get(msg, &error, &error_msg))
{
ERR("%s %s", error, error_msg);
return;
}
- if (!edbus_message_arguments_get(msg, "u(ia{sv}av)", &revision, &layout))
+ if (!eldbus_message_arguments_get(msg, "u(ia{sv}av)", &revision, &layout))
{
ERR("Error reading message");
return;
@@ -250,14 +250,14 @@ dbus_menu_find(E_DBusMenu_Ctx *ctx, int id)
}
static void
-menu_pop_request(void *data, const EDBus_Message *msg)
+menu_pop_request(void *data, const Eldbus_Message *msg)
{
E_DBusMenu_Ctx *ctx = data;
int id;
unsigned timestamp;
E_DBusMenu_Item *m;
- if (!edbus_message_arguments_get(msg, "iu", &id, &timestamp))
+ if (!eldbus_message_arguments_get(msg, "iu", &id, &timestamp))
{
ERR("Error reading values.");
return;
@@ -271,38 +271,38 @@ menu_pop_request(void *data, const EDBus_Message *msg)
}
static void
-icon_theme_path_get_cb(void *data EINA_UNUSED, const EDBus_Message *msg, EDBus_Pending *pending EINA_UNUSED)
+icon_theme_path_get_cb(void *data EINA_UNUSED, const Eldbus_Message *msg, Eldbus_Pending *pending EINA_UNUSED)
{
const char *error, *error_msg;
- EDBus_Message_Iter *var, *array;
+ Eldbus_Message_Iter *var, *array;
const char *path;
- if (edbus_message_error_get(msg, &error, &error_msg))
+ if (eldbus_message_error_get(msg, &error, &error_msg))
{
ERR("%s %s", error, error_msg);
return;
}
- if (!edbus_message_arguments_get(msg, "v", &var) ||
- !edbus_message_iter_arguments_get(var, "as", &array))
+ if (!eldbus_message_arguments_get(msg, "v", &var) ||
+ !eldbus_message_iter_arguments_get(var, "as", &array))
{
ERR("Error reading message.");
return;
}
- while (edbus_message_iter_get_and_next(array, 's', &path))
+ while (eldbus_message_iter_get_and_next(array, 's', &path))
{
//TODO
}
}
static void
-prop_changed_cb(void *data EINA_UNUSED, const EDBus_Message *msg)
+prop_changed_cb(void *data EINA_UNUSED, const Eldbus_Message *msg)
{
const char *interface, *propname;
- EDBus_Message_Iter *variant, *array;
+ Eldbus_Message_Iter *variant, *array;
- if (!edbus_message_arguments_get(msg, "ssv", &interface, &propname, &variant))
+ if (!eldbus_message_arguments_get(msg, "ssv", &interface, &propname, &variant))
{
ERR("Error getting values");
return;
@@ -311,7 +311,7 @@ prop_changed_cb(void *data EINA_UNUSED, const EDBus_Message *msg)
if (strcmp(propname, "IconThemePath"))
return;
- if (!edbus_message_iter_arguments_get(variant, "as", &array))
+ if (!eldbus_message_iter_arguments_get(variant, "as", &array))
{
//TODO
}
@@ -320,27 +320,27 @@ prop_changed_cb(void *data EINA_UNUSED, const EDBus_Message *msg)
static void
layout_update(E_DBusMenu_Ctx *ctx)
{
- EDBus_Message *msg;
- EDBus_Message_Iter *main_iter, *array;
-
- msg = edbus_proxy_method_call_new(ctx->proxy, "GetLayout");
- main_iter = edbus_message_iter_get(msg);
- edbus_message_iter_arguments_append(main_iter, "iias", 0, -1, &array);
- edbus_message_iter_container_close(main_iter, array);
- edbus_proxy_send(ctx->proxy, msg, layout_get_cb, ctx, -1);
+ Eldbus_Message *msg;
+ Eldbus_Message_Iter *main_iter, *array;
+
+ msg = eldbus_proxy_method_call_new(ctx->proxy, "GetLayout");
+ main_iter = eldbus_message_iter_get(msg);
+ eldbus_message_iter_arguments_append(main_iter, "iias", 0, -1, &array);
+ eldbus_message_iter_container_close(main_iter, array);
+ eldbus_proxy_send(ctx->proxy, msg, layout_get_cb, ctx, -1);
}
static void
-layout_updated_cb(void *data, const EDBus_Message *msg EINA_UNUSED)
+layout_updated_cb(void *data, const Eldbus_Message *msg EINA_UNUSED)
{
E_DBusMenu_Ctx *ctx = data;
layout_update(ctx);
}
EAPI E_DBusMenu_Ctx *
-e_dbusmenu_load(EDBus_Connection *conn, const char *bus, const char *path, const void *data)
+e_dbusmenu_load(Eldbus_Connection *conn, const char *bus, const char *path, const void *data)
{
- EDBus_Object *obj;
+ Eldbus_Object *obj;
E_DBusMenu_Ctx *ctx;
EINA_SAFETY_ON_NULL_RETURN_VAL(bus, NULL);
EINA_SAFETY_ON_NULL_RETURN_VAL(path, NULL);
@@ -350,23 +350,23 @@ e_dbusmenu_load(EDBus_Connection *conn, const char *bus, const char *path, const
ctx->data = (void *)data;
- edbus_connection_ref(conn);
- obj = edbus_object_get(conn, bus, path);
- ctx->proxy = edbus_proxy_get(obj, DBUS_MENU_IFACE);
+ eldbus_connection_ref(conn);
+ obj = eldbus_object_get(conn, bus, path);
+ ctx->proxy = eldbus_proxy_get(obj, DBUS_MENU_IFACE);
layout_update(ctx);
- edbus_proxy_signal_handler_add(ctx->proxy,
+ eldbus_proxy_signal_handler_add(ctx->proxy,
"ItemActivationRequested",
menu_pop_request, ctx);
- edbus_proxy_property_get(ctx->proxy, "IconThemePath",
+ eldbus_proxy_property_get(ctx->proxy, "IconThemePath",
icon_theme_path_get_cb, ctx);
- edbus_proxy_properties_changed_callback_add(ctx->proxy,
+ eldbus_proxy_properties_changed_callback_add(ctx->proxy,
prop_changed_cb, ctx);
- edbus_proxy_signal_handler_add(ctx->proxy, "ItemsPropertiesUpdated",
+ eldbus_proxy_signal_handler_add(ctx->proxy, "ItemsPropertiesUpdated",
layout_updated_cb, ctx);
- edbus_proxy_signal_handler_add(ctx->proxy, "LayoutUpdated",
+ eldbus_proxy_signal_handler_add(ctx->proxy, "LayoutUpdated",
layout_updated_cb, ctx);
return ctx;
}
@@ -374,44 +374,44 @@ e_dbusmenu_load(EDBus_Connection *conn, const char *bus, const char *path, const
EAPI void
e_dbusmenu_event_send(E_DBusMenu_Item *m, E_DBusMenu_Item_Event event)
{
- EDBus_Message *msg;
- EDBus_Message_Iter *main_iter, *var;
+ Eldbus_Message *msg;
+ Eldbus_Message_Iter *main_iter, *var;
unsigned int timestamp = (unsigned int)time(NULL);
EINA_SAFETY_ON_NULL_RETURN(m);
EINA_SAFETY_ON_FALSE_RETURN(event < E_DBUSMENU_ITEM_EVENT_LAST);
EINA_SAFETY_ON_NULL_RETURN(m->ctx);
- msg = edbus_proxy_method_call_new(m->ctx->proxy, "Event");
- main_iter = edbus_message_iter_get(msg);
- edbus_message_iter_arguments_append(main_iter, "is", m->id,
+ msg = eldbus_proxy_method_call_new(m->ctx->proxy, "Event");
+ main_iter = eldbus_message_iter_get(msg);
+ eldbus_message_iter_arguments_append(main_iter, "is", m->id,
Menu_Item_Event_Names[event]);
- var = edbus_message_iter_container_new(main_iter, 'v', "s");
+ var = eldbus_message_iter_container_new(main_iter, 'v', "s");
/* dummy data */
- edbus_message_iter_arguments_append(var, "s", "");
- edbus_message_iter_container_close(main_iter, var);
+ eldbus_message_iter_arguments_append(var, "s", "");
+ eldbus_message_iter_container_close(main_iter, var);
- edbus_message_iter_arguments_append(main_iter, "u", timestamp);
+ eldbus_message_iter_arguments_append(main_iter, "u", timestamp);
- edbus_proxy_send(m->ctx->proxy, msg, NULL, NULL, -1);
- edbus_message_unref(msg);
+ eldbus_proxy_send(m->ctx->proxy, msg, NULL, NULL, -1);
+ eldbus_message_unref(msg);
}
EAPI void
e_dbusmenu_unload(E_DBusMenu_Ctx *ctx)
{
- EDBus_Connection *conn;
- EDBus_Object *obj;
+ Eldbus_Connection *conn;
+ Eldbus_Object *obj;
EINA_SAFETY_ON_NULL_RETURN(ctx);
if (ctx->root_menu)
dbus_menu_free(ctx->root_menu);
- obj = edbus_proxy_object_get(ctx->proxy);
- conn = edbus_object_connection_get(obj);
- edbus_proxy_unref(ctx->proxy);
- edbus_object_unref(obj);
- edbus_connection_unref(conn);
+ obj = eldbus_proxy_object_get(ctx->proxy);
+ conn = eldbus_object_connection_get(obj);
+ eldbus_proxy_unref(ctx->proxy);
+ eldbus_object_unref(obj);
+ eldbus_connection_unref(conn);
free(ctx);
}
diff --git a/src/bin/e_dbusmenu.h b/src/bin/e_dbusmenu.h
index 133c1950c..84005ffef 100644
--- a/src/bin/e_dbusmenu.h
+++ b/src/bin/e_dbusmenu.h
@@ -2,7 +2,7 @@
#define _E_DBUSMENU_H_
#include <Eina.h>
-#include <EDBus.h>
+#include <Eldbus.h>
typedef enum {
E_DBUSMENU_ITEM_TYPE_STANDARD = 0,
@@ -61,7 +61,7 @@ struct _E_DBusMenu_Item
typedef void (*E_DBusMenu_Pop_Request_Cb)(void *data, const E_DBusMenu_Item *item);
typedef void (*E_DBusMenu_Update_Cb)(void *data, E_DBusMenu_Item *new_root_item);
-EAPI E_DBusMenu_Ctx * e_dbusmenu_load(EDBus_Connection *conn, const char *bus, const char *path, const void *data);
+EAPI E_DBusMenu_Ctx * e_dbusmenu_load(Eldbus_Connection *conn, const char *bus, const char *path, const void *data);
EAPI void e_dbusmenu_unload(E_DBusMenu_Ctx *ctx);
EAPI void e_dbusmenu_update_cb_set(E_DBusMenu_Ctx *menu_data, E_DBusMenu_Update_Cb cb);
EAPI void e_dbusmenu_pop_request_cb_set(E_DBusMenu_Ctx *menu_data, E_DBusMenu_Pop_Request_Cb cb);
diff --git a/src/bin/e_fm/e_fm_main.c b/src/bin/e_fm/e_fm_main.c
index 6e670b5ed..3d45b063c 100644
--- a/src/bin/e_fm/e_fm_main.c
+++ b/src/bin/e_fm/e_fm_main.c
@@ -71,7 +71,7 @@ static Efm_Mode mode = EFM_MODE_USING_RASTER_MOUNT;
/* FIXME: things to add to the slave enlightenment_fm process and ipc to e:
*
* * reporting results of fop's (current status - what has been don, what failed etc.)
- * * dbus removable device monitoring (in e17 itself now via edbus - move to enlightenment_fm and ipc removable device add/del and anything else)
+ * * dbus removable device monitoring (in e17 itself now via eldbus - move to enlightenment_fm and ipc removable device add/del and anything else)
* * mount/umount of removable devices (to go along with removable device support - put it in here and message back mount success/failure and where it is now mounted - remove from e17 itself)
*
*/
diff --git a/src/bin/e_fm/e_fm_main_udisks.c b/src/bin/e_fm/e_fm_main_udisks.c
index e6f09a228..1be01f8ac 100644
--- a/src/bin/e_fm/e_fm_main_udisks.c
+++ b/src/bin/e_fm/e_fm_main_udisks.c
@@ -45,7 +45,7 @@ void *alloca(size_t);
#include <Ecore_Ipc.h>
#include <Ecore_File.h>
#include <Eet.h>
-#include <EDBus.h>
+#include <Eldbus.h>
#include "e_fm_shared_device.h"
#include "e_fm_shared_codec.h"
@@ -60,22 +60,22 @@ void *alloca(size_t);
#define UDISKS_INTERFACE "org.freedesktop.UDisks"
#define UDISKS_DEVICE_INTERFACE "org.freedesktop.UDisks.Device"
-static EDBus_Connection *_e_fm_main_udisks_conn = NULL;
-static EDBus_Proxy *_e_fm_main_udisks_proxy = NULL;
+static Eldbus_Connection *_e_fm_main_udisks_conn = NULL;
+static Eldbus_Proxy *_e_fm_main_udisks_proxy = NULL;
static Eina_List *_e_stores = NULL;
static Eina_List *_e_vols = NULL;
-static void _e_fm_main_udisks_cb_dev_all(void *data, const EDBus_Message *msg,
- EDBus_Pending *pending);
-static void _e_fm_main_udisks_cb_dev_verify(void *data, const EDBus_Message *msg,
- EDBus_Pending *pending);
-static void _e_fm_main_udisks_cb_dev_add(void *data, const EDBus_Message *msg);
-static void _e_fm_main_udisks_cb_dev_del(void *data, const EDBus_Message *msg);
-static void _e_fm_main_udisks_cb_prop_modified(void *data, const EDBus_Message *msg);
-static void _e_fm_main_udisks_cb_store_prop(void *data, const EDBus_Message *msg,
- EDBus_Pending *pending);
-static void _e_fm_main_udisks_cb_vol_prop(void *data, const EDBus_Message *msg,
- EDBus_Pending *pending);
+static void _e_fm_main_udisks_cb_dev_all(void *data, const Eldbus_Message *msg,
+ Eldbus_Pending *pending);
+static void _e_fm_main_udisks_cb_dev_verify(void *data, const Eldbus_Message *msg,
+ Eldbus_Pending *pending);
+static void _e_fm_main_udisks_cb_dev_add(void *data, const Eldbus_Message *msg);
+static void _e_fm_main_udisks_cb_dev_del(void *data, const Eldbus_Message *msg);
+static void _e_fm_main_udisks_cb_prop_modified(void *data, const Eldbus_Message *msg);
+static void _e_fm_main_udisks_cb_store_prop(void *data, const Eldbus_Message *msg,
+ Eldbus_Pending *pending);
+static void _e_fm_main_udisks_cb_vol_prop(void *data, const Eldbus_Message *msg,
+ Eldbus_Pending *pending);
static void _e_fm_main_udisks_cb_vol_mounted(E_Volume *v);
static void _e_fm_main_udisks_cb_vol_unmounted(E_Volume *v);
static void _e_fm_main_udisks_cb_vol_unmounted_before_eject(E_Volume *v);
@@ -95,56 +95,56 @@ static E_Volume *_volume_find_by_dbus_path(const char *path);
static void _volume_del(E_Volume *v);
static void
-_e_fm_main_udisks_name_start(void *data __UNUSED__, const EDBus_Message *msg,
- EDBus_Pending *pending __UNUSED__)
+_e_fm_main_udisks_name_start(void *data __UNUSED__, const Eldbus_Message *msg,
+ Eldbus_Pending *pending __UNUSED__)
{
unsigned flag = 0;
- EDBus_Object *obj;
+ Eldbus_Object *obj;
- if (!edbus_message_arguments_get(msg, "u", &flag) || !flag)
+ if (!eldbus_message_arguments_get(msg, "u", &flag) || !flag)
{
_e_fm_main_udisks_catch(EINA_FALSE);
return;
}
- obj = edbus_object_get(_e_fm_main_udisks_conn, UDISKS_BUS, UDISKS_PATH);
- _e_fm_main_udisks_proxy = edbus_proxy_get(obj, UDISKS_INTERFACE);
+ obj = eldbus_object_get(_e_fm_main_udisks_conn, UDISKS_BUS, UDISKS_PATH);
+ _e_fm_main_udisks_proxy = eldbus_proxy_get(obj, UDISKS_INTERFACE);
- edbus_proxy_call(_e_fm_main_udisks_proxy, "EnumerateDevices",
+ eldbus_proxy_call(_e_fm_main_udisks_proxy, "EnumerateDevices",
_e_fm_main_udisks_cb_dev_all, NULL, -1, "");
- edbus_proxy_signal_handler_add(_e_fm_main_udisks_proxy, "DeviceAdded",
+ eldbus_proxy_signal_handler_add(_e_fm_main_udisks_proxy, "DeviceAdded",
_e_fm_main_udisks_cb_dev_add, NULL);
- edbus_proxy_signal_handler_add(_e_fm_main_udisks_proxy, "DeviceRemoved",
+ eldbus_proxy_signal_handler_add(_e_fm_main_udisks_proxy, "DeviceRemoved",
_e_fm_main_udisks_cb_dev_del, NULL);
_e_fm_main_udisks_catch(EINA_TRUE); /* signal usage of udisks for mounting */
}
static void
-_e_fm_main_udisks_cb_dev_all(void *data __UNUSED__, const EDBus_Message *msg,
- EDBus_Pending *pending __UNUSED__)
+_e_fm_main_udisks_cb_dev_all(void *data __UNUSED__, const Eldbus_Message *msg,
+ Eldbus_Pending *pending __UNUSED__)
{
const char *name, *txt, *path;
- EDBus_Message_Iter *array;
+ Eldbus_Message_Iter *array;
- if (edbus_message_error_get(msg, &name, &txt))
+ if (eldbus_message_error_get(msg, &name, &txt))
{
ERR("Error %s %s.", name, txt);
return;
}
- if (!edbus_message_arguments_get(msg, "ao", &array))
+ if (!eldbus_message_arguments_get(msg, "ao", &array))
{
ERR("Error getting arguments.");
return;
}
- while (edbus_message_iter_get_and_next(array, 'o', &path))
+ while (eldbus_message_iter_get_and_next(array, 'o', &path))
{
- EDBus_Message *new_msg;
- new_msg = edbus_message_method_call_new(UDISKS_BUS, path,
- EDBUS_FDO_INTERFACE_PROPERTIES, "Get");
- edbus_message_arguments_append(new_msg, "ss", UDISKS_DEVICE_INTERFACE, "IdUsage");
- edbus_connection_send(_e_fm_main_udisks_conn, new_msg,
+ Eldbus_Message *new_msg;
+ new_msg = eldbus_message_method_call_new(UDISKS_BUS, path,
+ ELDBUS_FDO_INTERFACE_PROPERTIES, "Get");
+ eldbus_message_arguments_append(new_msg, "ss", UDISKS_DEVICE_INTERFACE, "IdUsage");
+ eldbus_connection_send(_e_fm_main_udisks_conn, new_msg,
_e_fm_main_udisks_cb_dev_verify,
eina_stringshare_add(path), -1);
INF("DB INIT DEV+: %s", path);
@@ -153,25 +153,25 @@ _e_fm_main_udisks_cb_dev_all(void *data __UNUSED__, const EDBus_Message *msg,
static void
-_e_fm_main_udisks_cb_dev_verify(void *data, const EDBus_Message *msg,
- EDBus_Pending *pending __UNUSED__)
+_e_fm_main_udisks_cb_dev_verify(void *data, const Eldbus_Message *msg,
+ Eldbus_Pending *pending __UNUSED__)
{
const char *name, *txt, *id_usage, *path = data;
- EDBus_Message_Iter *variant;
+ Eldbus_Message_Iter *variant;
- if (edbus_message_error_get(msg, &name, &txt))
+ if (eldbus_message_error_get(msg, &name, &txt))
{
ERR("Error %s %s.", name, txt);
goto error;
}
- if (!edbus_message_arguments_get(msg, "v", &variant))
+ if (!eldbus_message_arguments_get(msg, "v", &variant))
{
ERR("Error getting arguments.");
goto error;
}
- if (!edbus_message_iter_arguments_get(variant, "s", &id_usage))
+ if (!eldbus_message_iter_arguments_get(variant, "s", &id_usage))
{
ERR("Type of variant not expected");
goto error;
@@ -189,25 +189,25 @@ error:
}
static void
-_e_fm_main_udisks_cb_dev_verify_added(void *data, const EDBus_Message *msg,
- EDBus_Pending *pending __UNUSED__)
+_e_fm_main_udisks_cb_dev_verify_added(void *data, const Eldbus_Message *msg,
+ Eldbus_Pending *pending __UNUSED__)
{
const char *name, *txt, *id_usage, *path = data;
- EDBus_Message_Iter *variant;
+ Eldbus_Message_Iter *variant;
- if (edbus_message_error_get(msg, &name, &txt))
+ if (eldbus_message_error_get(msg, &name, &txt))
{
ERR("Error %s %s.", name, txt);
goto error;
}
- if (!edbus_message_arguments_get(msg, "v", &variant))
+ if (!eldbus_message_arguments_get(msg, "v", &variant))
{
ERR("Error getting arguments.");
goto error;
}
- if (!edbus_message_iter_arguments_get(variant, "s", &id_usage))
+ if (!eldbus_message_iter_arguments_get(variant, "s", &id_usage))
{
ERR("Type of variant not expected");
goto error;
@@ -221,7 +221,7 @@ _e_fm_main_udisks_cb_dev_verify_added(void *data, const EDBus_Message *msg,
if (!s)
_e_fm_main_udisks_storage_add(path);
else
- edbus_proxy_property_get_all(s->proxy,
+ eldbus_proxy_property_get_all(s->proxy,
_e_fm_main_udisks_cb_store_prop, s);
}
else if(!strcmp(id_usage, "filesystem"))
@@ -231,7 +231,7 @@ _e_fm_main_udisks_cb_dev_verify_added(void *data, const EDBus_Message *msg,
if (!v)
_e_fm_main_udisks_volume_add(path, EINA_TRUE);
else
- edbus_proxy_property_get_all(v->proxy,
+ eldbus_proxy_property_get_all(v->proxy,
_e_fm_main_udisks_cb_vol_prop, v);
}
else
@@ -242,37 +242,37 @@ error:
}
static void
-_e_fm_main_udisks_cb_dev_add(void *data __UNUSED__, const EDBus_Message *msg)
+_e_fm_main_udisks_cb_dev_add(void *data __UNUSED__, const Eldbus_Message *msg)
{
- EDBus_Message *new;
+ Eldbus_Message *new;
E_Volume *v;
char *path;
- if (!edbus_message_arguments_get(msg, "o", &path))
+ if (!eldbus_message_arguments_get(msg, "o", &path))
return;
DBG("DB DEV+: %s", path);
v = _volume_find_by_dbus_path(path);
if (v)
{
- edbus_proxy_property_get_all(v->proxy, _e_fm_main_udisks_cb_vol_prop, v);
+ eldbus_proxy_property_get_all(v->proxy, _e_fm_main_udisks_cb_vol_prop, v);
return;
}
- new = edbus_message_method_call_new(UDISKS_BUS, path, EDBUS_FDO_INTERFACE_PROPERTIES, "Get");
- edbus_message_arguments_append(new, "ss", UDISKS_DEVICE_INTERFACE, "IdUsage");
- edbus_connection_send(_e_fm_main_udisks_conn, new,
+ new = eldbus_message_method_call_new(UDISKS_BUS, path, ELDBUS_FDO_INTERFACE_PROPERTIES, "Get");
+ eldbus_message_arguments_append(new, "ss", UDISKS_DEVICE_INTERFACE, "IdUsage");
+ eldbus_connection_send(_e_fm_main_udisks_conn, new,
_e_fm_main_udisks_cb_dev_verify_added,
eina_stringshare_add(path), -1);
}
static void
-_e_fm_main_udisks_cb_dev_del(void *data __UNUSED__, const EDBus_Message *msg)
+_e_fm_main_udisks_cb_dev_del(void *data __UNUSED__, const Eldbus_Message *msg)
{
char *path;
E_Volume *v;
- if (!edbus_message_arguments_get(msg, "o", &path))
+ if (!eldbus_message_arguments_get(msg, "o", &path))
return;
DBG("DB DEV-: %s", path);
if ((v = _volume_find_by_dbus_path(path)))
@@ -286,10 +286,10 @@ _e_fm_main_udisks_cb_dev_del(void *data __UNUSED__, const EDBus_Message *msg)
static void
_e_fm_main_udisks_cb_prop_modified(void *data,
- const EDBus_Message *msg __UNUSED__)
+ const Eldbus_Message *msg __UNUSED__)
{
E_Volume *v = data;
- edbus_proxy_property_get_all(v->proxy, _e_fm_main_udisks_cb_vol_prop, v);
+ eldbus_proxy_property_get_all(v->proxy, _e_fm_main_udisks_cb_vol_prop, v);
}
static Eina_Bool
@@ -301,41 +301,41 @@ _storage_del(void *data)
}
static void
-_e_fm_main_udisks_cb_store_prop(void *data, const EDBus_Message *msg,
- EDBus_Pending *pending __UNUSED__)
+_e_fm_main_udisks_cb_store_prop(void *data, const Eldbus_Message *msg,
+ Eldbus_Pending *pending __UNUSED__)
{
E_Storage *s = data;
const char *name, *txt;
- EDBus_Message_Iter *dict, *entry;
+ Eldbus_Message_Iter *dict, *entry;
- if (edbus_message_error_get(msg, &name, &txt))
+ if (eldbus_message_error_get(msg, &name, &txt))
{
ERR("Error %s %s.", name, txt);
return;
}
- if (!edbus_message_arguments_get(msg, "a{sv}", &dict))
+ if (!eldbus_message_arguments_get(msg, "a{sv}", &dict))
{
ERR("Error getting arguments.");
return;
}
- while (edbus_message_iter_get_and_next(dict, 'e', &entry))
+ while (eldbus_message_iter_get_and_next(dict, 'e', &entry))
{
char *key;
- EDBus_Message_Iter *var;
+ Eldbus_Message_Iter *var;
- if (!edbus_message_iter_arguments_get(entry, "sv", &key, &var))
+ if (!eldbus_message_iter_arguments_get(entry, "sv", &key, &var))
continue;
if (!strcmp(key, "DeviceFile"))
{
const char *udi;
- if (edbus_message_iter_arguments_get(var, "s", &udi))
+ if (eldbus_message_iter_arguments_get(var, "s", &udi))
eina_stringshare_replace(&s->udi, udi);
}
else if (!strcmp(key, "DriveConnectionInterface"))
{
const char *bus;
- if (edbus_message_iter_arguments_get(var, "s", &bus))
+ if (eldbus_message_iter_arguments_get(var, "s", &bus))
{
if (s->bus)
eina_stringshare_del(bus);
@@ -344,13 +344,13 @@ _e_fm_main_udisks_cb_store_prop(void *data, const EDBus_Message *msg,
}
else if (!strcmp(key, "DriveMediaCompatibility"))
{
- EDBus_Message_Iter *inner_array;
+ Eldbus_Message_Iter *inner_array;
const char *media;
- if (!edbus_message_iter_arguments_get(var, "as", &inner_array))
+ if (!eldbus_message_iter_arguments_get(var, "as", &inner_array))
continue;
- while(edbus_message_iter_get_and_next(inner_array, 's', &media))
+ while(eldbus_message_iter_get_and_next(inner_array, 's', &media))
{
eina_stringshare_replace(&s->drive_type, media);
break;
@@ -359,13 +359,13 @@ _e_fm_main_udisks_cb_store_prop(void *data, const EDBus_Message *msg,
else if (!strcmp(key, "DriveModel"))
{
const char *model;
- if (edbus_message_iter_arguments_get(var, "s", &model))
+ if (eldbus_message_iter_arguments_get(var, "s", &model))
eina_stringshare_replace(&s->model, model);
}
else if (!strcmp(key, "DriveVendor"))
{
const char *vendor;
- if (edbus_message_iter_arguments_get(var, "s", &vendor))
+ if (eldbus_message_iter_arguments_get(var, "s", &vendor))
{
if (s->vendor)
eina_stringshare_del(s->vendor);
@@ -375,7 +375,7 @@ _e_fm_main_udisks_cb_store_prop(void *data, const EDBus_Message *msg,
else if (!strcmp(key, "DriveSerial"))
{
const char *serial;
- if (edbus_message_iter_arguments_get(var, "s", &serial))
+ if (eldbus_message_iter_arguments_get(var, "s", &serial))
{
if (s->serial)
eina_stringshare_del(s->serial);
@@ -383,21 +383,21 @@ _e_fm_main_udisks_cb_store_prop(void *data, const EDBus_Message *msg,
}
}
else if (!strcmp(key, "DeviceIsSystemInternal"))
- edbus_message_iter_arguments_get(var, "b", &s->system_internal);
+ eldbus_message_iter_arguments_get(var, "b", &s->system_internal);
else if (!strcmp(key, "DeviceIsMediaAvailable"))
- edbus_message_iter_arguments_get(var, "b", &s->media_available);
+ eldbus_message_iter_arguments_get(var, "b", &s->media_available);
else if (!strcmp(key, "DeviceSize"))
- edbus_message_iter_arguments_get(var, "t", &s->media_size);
+ eldbus_message_iter_arguments_get(var, "t", &s->media_size);
else if (!strcmp(key, "DriveIsMediaEjectable"))
- edbus_message_iter_arguments_get(var, "b", &s->requires_eject);
+ eldbus_message_iter_arguments_get(var, "b", &s->requires_eject);
else if (!strcmp(key, "DriveCanDetach"))
- edbus_message_iter_arguments_get(var, "b", &s->hotpluggable);
+ eldbus_message_iter_arguments_get(var, "b", &s->hotpluggable);
else if (!strcmp(key, "DeviceIsMediaChangeDetectionInhibited"))
- edbus_message_iter_arguments_get(var, "b", &s->media_check_enabled);
+ eldbus_message_iter_arguments_get(var, "b", &s->media_check_enabled);
else if (!strcmp(key, "DevicePresentationIconName"))
{
const char *icon;
- if (edbus_message_iter_arguments_get(var, "s", &icon))
+ if (eldbus_message_iter_arguments_get(var, "s", &icon))
{
if (s->icon.drive)
eina_stringshare_del(s->icon.drive);
@@ -450,39 +450,39 @@ _idler_volume_del(void *data)
}
static void
-_e_fm_main_udisks_cb_vol_prop(void *data, const EDBus_Message *msg,
- EDBus_Pending *pending __UNUSED__)
+_e_fm_main_udisks_cb_vol_prop(void *data, const Eldbus_Message *msg,
+ Eldbus_Pending *pending __UNUSED__)
{
E_Volume *v = data;
E_Storage *s = NULL;
const char *txt, *message;
- EDBus_Message_Iter *array, *dict;
+ Eldbus_Message_Iter *array, *dict;
DBG("volume=%s",v->dbus_path);
- if (edbus_message_error_get(msg, &txt, &message))
+ if (eldbus_message_error_get(msg, &txt, &message))
{
ERR("Error: %s %s\nVolume: %s", txt, message, v->udi);
return;
}
- if (!edbus_message_arguments_get(msg, "a{sv}", &array))
+ if (!eldbus_message_arguments_get(msg, "a{sv}", &array))
{
ERR("Error getting values.");
return;
}
- while (edbus_message_iter_get_and_next(array, 'e', &dict))
+ while (eldbus_message_iter_get_and_next(array, 'e', &dict))
{
- EDBus_Message_Iter *var;
+ Eldbus_Message_Iter *var;
const char *key;
- if (!edbus_message_iter_arguments_get(dict, "sv", &key, &var))
+ if (!eldbus_message_iter_arguments_get(dict, "sv", &key, &var))
continue;
if (!strcmp(key, "DeviceFile"))
{
const char *udi;
- if (!edbus_message_iter_arguments_get(var, "s", &udi))
+ if (!eldbus_message_iter_arguments_get(var, "s", &udi))
continue;
if (udi && v->first_time)
eina_stringshare_replace(&v->udi, udi);
@@ -490,7 +490,7 @@ _e_fm_main_udisks_cb_vol_prop(void *data, const EDBus_Message *msg,
else if (!strcmp(key, "DeviceIsSystemInternal"))
{
Eina_Bool internal;
- edbus_message_iter_arguments_get(var, "b", &internal);
+ eldbus_message_iter_arguments_get(var, "b", &internal);
if (internal)
{
DBG("removing is internal %s", v->dbus_path);
@@ -501,7 +501,7 @@ _e_fm_main_udisks_cb_vol_prop(void *data, const EDBus_Message *msg,
else if (!strcmp(key, "DeviceIsMediaChangeDetectionInhibited"))
{
Eina_Bool inibited;
- edbus_message_iter_arguments_get(var, "b", &inibited);
+ eldbus_message_iter_arguments_get(var, "b", &inibited);
if (inibited)
{
/* skip volumes with volume.ignore set */
@@ -511,30 +511,30 @@ _e_fm_main_udisks_cb_vol_prop(void *data, const EDBus_Message *msg,
}
}
else if (!strcmp(key, "DeviceIsLuks"))
- edbus_message_iter_arguments_get(var, "b", &v->encrypted);
+ eldbus_message_iter_arguments_get(var, "b", &v->encrypted);
else if (!strcmp(key, "IdUuid"))
{
const char *uuid;
- if (!edbus_message_iter_arguments_get(var, "s", &uuid))
+ if (!eldbus_message_iter_arguments_get(var, "s", &uuid))
continue;
eina_stringshare_replace(&v->uuid, uuid);
}
else if (!strcmp(key, "IdLabel"))
{
const char *label;
- if (!edbus_message_iter_arguments_get(var, "s", &label))
+ if (!eldbus_message_iter_arguments_get(var, "s", &label))
continue;
eina_stringshare_replace(&v->label, label);
}
else if (!strcmp(key, "DeviceMountPaths"))
{
- EDBus_Message_Iter *inner_array;
+ Eldbus_Message_Iter *inner_array;
const char *path;
- if (!edbus_message_iter_arguments_get(var, "as", &inner_array))
+ if (!eldbus_message_iter_arguments_get(var, "as", &inner_array))
continue;
- while (edbus_message_iter_get_and_next(inner_array, 's', &path))
+ while (eldbus_message_iter_get_and_next(inner_array, 's', &path))
{
eina_stringshare_replace(&v->mount_point, path);
break;
@@ -543,24 +543,24 @@ _e_fm_main_udisks_cb_vol_prop(void *data, const EDBus_Message *msg,
else if (!strcmp(key, "IdType"))
{
const char *type;
- if (!edbus_message_iter_arguments_get(var, "s", &type))
+ if (!eldbus_message_iter_arguments_get(var, "s", &type))
continue;
eina_stringshare_replace(&v->fstype, type);
}
else if (!strcmp(key, "DeviceSize"))
- edbus_message_iter_arguments_get(var, "t", &v->size);
+ eldbus_message_iter_arguments_get(var, "t", &v->size);
else if (!strcmp(key, "DeviceIsMounted"))
- edbus_message_iter_arguments_get(var, "b", &v->mounted);
+ eldbus_message_iter_arguments_get(var, "b", &v->mounted);
else if (!strcmp(key, "DeviceIsLuksCleartext"))
- edbus_message_iter_arguments_get(var, "b", &v->unlocked);
+ eldbus_message_iter_arguments_get(var, "b", &v->unlocked);
else if (!strcmp(key, "DeviceIsPartition"))
- edbus_message_iter_arguments_get(var, "b", &v->partition);
+ eldbus_message_iter_arguments_get(var, "b", &v->partition);
else if (!strcmp(key, "PartitionNumber"))
- edbus_message_iter_arguments_get(var, "i", &v->partition_number);
+ eldbus_message_iter_arguments_get(var, "i", &v->partition_number);
else if (!strcmp(key, "PartitionLabel"))
{
const char *partition_label;
- if (!edbus_message_iter_arguments_get(var, "s", &partition_label))
+ if (!eldbus_message_iter_arguments_get(var, "s", &partition_label))
continue;
eina_stringshare_replace(&v->partition_label, partition_label);
}
@@ -568,7 +568,7 @@ _e_fm_main_udisks_cb_vol_prop(void *data, const EDBus_Message *msg,
{
const char *enc;
E_Volume *venc;
- if (!edbus_message_iter_arguments_get(var, "o", &enc))
+ if (!eldbus_message_iter_arguments_get(var, "o", &enc))
continue;
eina_stringshare_replace(&v->partition_label, enc);
venc = _e_fm_main_udisks_volume_find(enc);
@@ -581,7 +581,7 @@ _e_fm_main_udisks_cb_vol_prop(void *data, const EDBus_Message *msg,
else if (!strcmp(key, "PartitionSlave"))
{
char *partition_slave, buf[4096];
- if (!edbus_message_iter_arguments_get(var, "o", &partition_slave))
+ if (!eldbus_message_iter_arguments_get(var, "o", &partition_slave))
continue;
if ((!partition_slave) || (strlen(partition_slave) < sizeof("/org/freedesktop/UDisks/devices/")))
eina_stringshare_replace(&v->parent, partition_slave);
@@ -688,7 +688,7 @@ _e_fm_main_udisks_vol_mount_timeout(E_Volume *v)
v->guard = NULL;
if (v->op)
- edbus_pending_cancel(v->op);
+ eldbus_pending_cancel(v->op);
v->op = NULL;
v->optype = E_VOLUME_OP_TYPE_NONE;
size = _e_fm_main_udisks_format_error_msg(&buf, v,
@@ -737,7 +737,7 @@ _e_fm_main_udisks_vol_unmount_timeout(E_Volume *v)
v->guard = NULL;
if (v->op)
- edbus_pending_cancel(v->op);
+ eldbus_pending_cancel(v->op);
v->op = NULL;
v->optype = E_VOLUME_OP_TYPE_NONE;
size = _e_fm_main_udisks_format_error_msg(&buf, v,
@@ -788,7 +788,7 @@ _e_fm_main_udisks_vol_eject_timeout(E_Volume *v)
v->guard = NULL;
if (v->op)
- edbus_pending_cancel(v->op);
+ eldbus_pending_cancel(v->op);
v->op = NULL;
v->optype = E_VOLUME_OP_TYPE_NONE;
size = _e_fm_main_udisks_format_error_msg(&buf, v,
@@ -802,63 +802,63 @@ _e_fm_main_udisks_vol_eject_timeout(E_Volume *v)
}
static void
-_volume_task_cb(void *data __UNUSED__, const EDBus_Message *msg __UNUSED__,
- EDBus_Pending *pending __UNUSED__)
+_volume_task_cb(void *data __UNUSED__, const Eldbus_Message *msg __UNUSED__,
+ Eldbus_Pending *pending __UNUSED__)
{
/**
- * if edbus_proxy_send has callback == NULL it will return a NULL
- * but we need a EDBus_Pending to be able to cancel it when timeout occurs
+ * if eldbus_proxy_send has callback == NULL it will return a NULL
+ * but we need a Eldbus_Pending to be able to cancel it when timeout occurs
*/
/* FIXME: this should not matter. If we don't have a callback, there's no
- * reason to cancel it... cancelling has no effect other than saying edbus we
+ * reason to cancel it... cancelling has no effect other than saying eldbus we
* are not interested in the return anymore. I.e.: don't bother to cancel it
*/
}
-static EDBus_Pending *
-_volume_umount(EDBus_Proxy *proxy)
+static Eldbus_Pending *
+_volume_umount(Eldbus_Proxy *proxy)
{
- EDBus_Message *msg;
- EDBus_Message_Iter *array, *main_iter;
+ Eldbus_Message *msg;
+ Eldbus_Message_Iter *array, *main_iter;
- msg = edbus_proxy_method_call_new(proxy, "FilesystemUnmount");
- main_iter = edbus_message_iter_get(msg);
- edbus_message_iter_arguments_append(main_iter, "as", &array);
- edbus_message_iter_container_close(main_iter, array);
+ msg = eldbus_proxy_method_call_new(proxy, "FilesystemUnmount");
+ main_iter = eldbus_message_iter_get(msg);
+ eldbus_message_iter_arguments_append(main_iter, "as", &array);
+ eldbus_message_iter_container_close(main_iter, array);
- return edbus_proxy_send(proxy, msg, _volume_task_cb, NULL, -1);
+ return eldbus_proxy_send(proxy, msg, _volume_task_cb, NULL, -1);
}
-static EDBus_Pending *
-_volume_eject(EDBus_Proxy *proxy)
+static Eldbus_Pending *
+_volume_eject(Eldbus_Proxy *proxy)
{
- EDBus_Message *msg;
- EDBus_Message_Iter *array, *main_iter;
+ Eldbus_Message *msg;
+ Eldbus_Message_Iter *array, *main_iter;
- msg = edbus_proxy_method_call_new(proxy, "DriveEject");
- main_iter = edbus_message_iter_get(msg);
- edbus_message_iter_arguments_append(main_iter, "as", &array);
- edbus_message_iter_container_close(main_iter, array);
+ msg = eldbus_proxy_method_call_new(proxy, "DriveEject");
+ main_iter = eldbus_message_iter_get(msg);
+ eldbus_message_iter_arguments_append(main_iter, "as", &array);
+ eldbus_message_iter_container_close(main_iter, array);
- return edbus_proxy_send(proxy, msg, _volume_task_cb, NULL, -1);
+ return eldbus_proxy_send(proxy, msg, _volume_task_cb, NULL, -1);
}
-static EDBus_Pending *
-_volume_mount(EDBus_Proxy *proxy, const char *fstype, Eina_List *opt)
+static Eldbus_Pending *
+_volume_mount(Eldbus_Proxy *proxy, const char *fstype, Eina_List *opt)
{
- EDBus_Message *msg;
- EDBus_Message_Iter *array, *main_iter;
+ Eldbus_Message *msg;
+ Eldbus_Message_Iter *array, *main_iter;
Eina_List *l;
const char *opt_txt;
- msg = edbus_proxy_method_call_new(proxy, "FilesystemMount");
- main_iter = edbus_message_iter_get(msg);
- edbus_message_iter_arguments_append(main_iter, "sas", fstype, &array);
+ msg = eldbus_proxy_method_call_new(proxy, "FilesystemMount");
+ main_iter = eldbus_message_iter_get(msg);
+ eldbus_message_iter_arguments_append(main_iter, "sas", fstype, &array);
EINA_LIST_FOREACH(opt, l, opt_txt)
- edbus_message_iter_basic_append(array, 's', opt_txt);
- edbus_message_iter_container_close(main_iter, array);
+ eldbus_message_iter_basic_append(array, 's', opt_txt);
+ eldbus_message_iter_container_close(main_iter, array);
- return edbus_proxy_send(proxy, msg, _volume_task_cb, NULL, -1);
+ return eldbus_proxy_send(proxy, msg, _volume_task_cb, NULL, -1);
}
static Eina_Bool
@@ -907,7 +907,7 @@ _e_fm_main_udisks_volume_add(const char *path,
Eina_Bool first_time)
{
E_Volume *v;
- EDBus_Object *obj;
+ Eldbus_Object *obj;
if (!path) return NULL;
if (_volume_find_by_dbus_path(path)) return NULL;
@@ -919,10 +919,10 @@ _e_fm_main_udisks_volume_add(const char *path,
v->icon = NULL;
v->first_time = first_time;
_e_vols = eina_list_append(_e_vols, v);
- obj = edbus_object_get(_e_fm_main_udisks_conn, UDISKS_BUS, path);
- v->proxy = edbus_proxy_get(obj, UDISKS_DEVICE_INTERFACE);
- edbus_proxy_property_get_all(v->proxy, _e_fm_main_udisks_cb_vol_prop, v);
- edbus_proxy_signal_handler_add(v->proxy, "Changed",
+ obj = eldbus_object_get(_e_fm_main_udisks_conn, UDISKS_BUS, path);
+ v->proxy = eldbus_proxy_get(obj, UDISKS_DEVICE_INTERFACE);
+ eldbus_proxy_property_get_all(v->proxy, _e_fm_main_udisks_cb_vol_prop, v);
+ eldbus_proxy_signal_handler_add(v->proxy, "Changed",
_e_fm_main_udisks_cb_prop_modified, v);
v->guard = NULL;
@@ -962,9 +962,9 @@ _volume_del(E_Volume *v)
*/
if (v->proxy)
{
- EDBus_Object *obj = edbus_proxy_object_get(v->proxy);
- edbus_proxy_unref(v->proxy);
- edbus_object_unref(obj);
+ Eldbus_Object *obj = eldbus_proxy_object_get(v->proxy);
+ eldbus_proxy_unref(v->proxy);
+ eldbus_object_unref(obj);
}
_e_vols = eina_list_remove(_e_vols, v);
_e_fm_shared_device_volume_free(v);
@@ -1084,11 +1084,11 @@ _e_fm_main_udisks_volume_mount(E_Volume *v)
void
_e_fm_main_udisks_init(void)
{
- edbus_init();
- _e_fm_main_udisks_conn = edbus_connection_get(EDBUS_CONNECTION_TYPE_SYSTEM);
+ eldbus_init();
+ _e_fm_main_udisks_conn = eldbus_connection_get(ELDBUS_CONNECTION_TYPE_SYSTEM);
if (!_e_fm_main_udisks_conn) return;
- edbus_name_start(_e_fm_main_udisks_conn, UDISKS_BUS, 0,
+ eldbus_name_start(_e_fm_main_udisks_conn, UDISKS_BUS, 0,
_e_fm_main_udisks_name_start, NULL);
}
@@ -1097,21 +1097,21 @@ _e_fm_main_udisks_shutdown(void)
{
if (_e_fm_main_udisks_proxy)
{
- EDBus_Object *obj;
- obj = edbus_proxy_object_get(_e_fm_main_udisks_proxy);
- edbus_proxy_unref(_e_fm_main_udisks_proxy);
- edbus_object_unref(obj);
+ Eldbus_Object *obj;
+ obj = eldbus_proxy_object_get(_e_fm_main_udisks_proxy);
+ eldbus_proxy_unref(_e_fm_main_udisks_proxy);
+ eldbus_object_unref(obj);
}
if (_e_fm_main_udisks_conn)
- edbus_connection_unref(_e_fm_main_udisks_conn);
- edbus_shutdown();
+ eldbus_connection_unref(_e_fm_main_udisks_conn);
+ eldbus_shutdown();
}
E_Storage *
_e_fm_main_udisks_storage_add(const char *path)
{
E_Storage *s;
- EDBus_Object *obj;
+ Eldbus_Object *obj;
if (!path) return NULL;
if (_storage_find_by_dbus_path(path)) return NULL;
@@ -1121,9 +1121,9 @@ _e_fm_main_udisks_storage_add(const char *path)
DBG("STORAGE+=%s", path);
s->dbus_path = path;
_e_stores = eina_list_append(_e_stores, s);
- obj = edbus_object_get(_e_fm_main_udisks_conn, UDISKS_BUS, path);
- s->proxy = edbus_proxy_get(obj, UDISKS_DEVICE_INTERFACE);
- edbus_proxy_property_get_all(s->proxy, _e_fm_main_udisks_cb_store_prop, s);
+ obj = eldbus_object_get(_e_fm_main_udisks_conn, UDISKS_BUS, path);
+ s->proxy = eldbus_proxy_get(obj, UDISKS_DEVICE_INTERFACE);
+ eldbus_proxy_property_get_all(s->proxy, _e_fm_main_udisks_cb_store_prop, s);
return s;
}
@@ -1145,9 +1145,9 @@ _e_fm_main_udisks_storage_del(const char *path)
_e_stores = eina_list_remove(_e_stores, s);
if (s->proxy)
{
- EDBus_Object *obj = edbus_proxy_object_get(s->proxy);
- edbus_proxy_unref(s->proxy);
- edbus_object_unref(obj);
+ Eldbus_Object *obj = eldbus_proxy_object_get(s->proxy);
+ eldbus_proxy_unref(s->proxy);
+ eldbus_object_unref(obj);
}
_e_fm_shared_device_storage_free(s);
}
diff --git a/src/bin/e_fm_cmdline.c b/src/bin/e_fm_cmdline.c
index 23810ab4b..11f498c4b 100644
--- a/src/bin/e_fm_cmdline.c
+++ b/src/bin/e_fm_cmdline.c
@@ -4,16 +4,16 @@
#include "e.h"
-static EDBus_Connection *conn = NULL;
+static Eldbus_Connection *conn = NULL;
static int retval = EXIT_SUCCESS;
static int pending = 0;
static void
-fm_open_reply(void *data __UNUSED__, const EDBus_Message *msg,
- EDBus_Pending *dbus_pending __UNUSED__)
+fm_open_reply(void *data __UNUSED__, const Eldbus_Message *msg,
+ Eldbus_Pending *dbus_pending __UNUSED__)
{
const char *name, *txt;
- if (edbus_message_error_get(msg, &name, &txt))
+ if (eldbus_message_error_get(msg, &name, &txt))
{
retval = EXIT_FAILURE;
ERR("%s: %s", name, txt);
@@ -33,7 +33,7 @@ fm_error_quit_last(void *data __UNUSED__)
static void
fm_open(const char *path)
{
- EDBus_Message *msg;
+ Eldbus_Message *msg;
const char *method;
char *p;
@@ -87,7 +87,7 @@ fm_open(const char *path)
else
method = "OpenFile";
- msg = edbus_message_method_call_new("org.enlightenment.FileManager",
+ msg = eldbus_message_method_call_new("org.enlightenment.FileManager",
"/org/enlightenment/FileManager",
"org.enlightenment.FileManager",
method);
@@ -98,13 +98,13 @@ fm_open(const char *path)
free(p);
return;
}
- edbus_message_arguments_append(msg, "s", p);
+ eldbus_message_arguments_append(msg, "s", p);
free(p);
- if (!edbus_connection_send(conn, msg, fm_open_reply, NULL, -1))
+ if (!eldbus_connection_send(conn, msg, fm_open_reply, NULL, -1))
{
ERR("Could not send DBus Message");
- edbus_message_unref(msg);
+ eldbus_message_unref(msg);
ecore_idler_add(fm_error_quit_last, NULL);
}
else
@@ -152,9 +152,9 @@ main(int argc, char *argv[])
ecore_init();
ecore_file_init();
- edbus_init();
+ eldbus_init();
- conn = edbus_connection_get(EDBUS_CONNECTION_TYPE_SESSION);
+ conn = eldbus_connection_get(ELDBUS_CONNECTION_TYPE_SESSION);
if (!conn)
{
ERR("Could not DBus SESSION bus.");
@@ -172,9 +172,9 @@ main(int argc, char *argv[])
}
ecore_main_loop_begin();
- edbus_connection_unref(conn);
+ eldbus_connection_unref(conn);
end:
- edbus_shutdown();
+ eldbus_shutdown();
ecore_file_shutdown();
ecore_shutdown();
return retval;
diff --git a/src/bin/e_fm_shared_types.h.in b/src/bin/e_fm_shared_types.h.in
index 2ae5f2a7f..d041b9ad7 100644
--- a/src/bin/e_fm_shared_types.h.in
+++ b/src/bin/e_fm_shared_types.h.in
@@ -9,7 +9,7 @@
# include <Eeze_Disk.h>
#endif
#if @DBUS_MOUNT_CONFIG@
-# include <EDBus.h>
+# include <Eldbus.h>
#endif
# define E_DEVICE_TYPE_STORAGE 1
@@ -71,7 +71,7 @@ struct _E_Storage
Eina_Bool validated : 1;
Eina_Bool trackable : 1;
#if @DBUS_MOUNT_CONFIG@
- EDBus_Proxy *proxy;
+ Eldbus_Proxy *proxy;
const char *dbus_path;
#endif
#if @EEZE_MOUNT_CONFIG@
@@ -111,8 +111,8 @@ struct _E_Volume
Eina_Bool unlocked;
#if @DBUS_MOUNT_CONFIG@
- EDBus_Pending *op;
- EDBus_Proxy *proxy;
+ Eldbus_Pending *op;
+ Eldbus_Proxy *proxy;
const char *dbus_path;
#endif
#if @EEZE_MOUNT_CONFIG@
diff --git a/src/bin/e_msgbus.c b/src/bin/e_msgbus.c
index 819a5f6c5..722724a44 100644
--- a/src/bin/e_msgbus.c
+++ b/src/bin/e_msgbus.c
@@ -1,39 +1,39 @@
#include "e.h"
/* local subsystem functions */
-static void _e_msgbus_request_name_cb(void *data, const EDBus_Message *msg,
- EDBus_Pending *pending);
-
-static EDBus_Message *_e_msgbus_core_restart_cb(const EDBus_Service_Interface *iface,
- const EDBus_Message *msg);
-static EDBus_Message *_e_msgbus_core_shutdown_cb(const EDBus_Service_Interface *iface,
- const EDBus_Message *msg);
-
-static EDBus_Message *_e_msgbus_module_load_cb(const EDBus_Service_Interface *iface,
- const EDBus_Message *msg);
-static EDBus_Message *_e_msgbus_module_unload_cb(const EDBus_Service_Interface *iface,
- const EDBus_Message *msg);
-static EDBus_Message *_e_msgbus_module_enable_cb(const EDBus_Service_Interface *iface,
- const EDBus_Message *msg);
-static EDBus_Message *_e_msgbus_module_disable_cb(const EDBus_Service_Interface *iface,
- const EDBus_Message *msg);
-static EDBus_Message *_e_msgbus_module_list_cb(const EDBus_Service_Interface *iface,
- const EDBus_Message *msg);
-
-static EDBus_Message *_e_msgbus_profile_set_cb(const EDBus_Service_Interface *iface,
- const EDBus_Message *msg);
-static EDBus_Message *_e_msgbus_profile_get_cb(const EDBus_Service_Interface *iface,
- const EDBus_Message *msg);
-static EDBus_Message *_e_msgbus_profile_list_cb(const EDBus_Service_Interface *iface,
- const EDBus_Message *msg);
-static EDBus_Message *_e_msgbus_profile_add_cb(const EDBus_Service_Interface *iface,
- const EDBus_Message *msg);
-static EDBus_Message *_e_msgbus_profile_delete_cb(const EDBus_Service_Interface *iface,
- const EDBus_Message *msg);
+static void _e_msgbus_request_name_cb(void *data, const Eldbus_Message *msg,
+ Eldbus_Pending *pending);
+
+static Eldbus_Message *_e_msgbus_core_restart_cb(const Eldbus_Service_Interface *iface,
+ const Eldbus_Message *msg);
+static Eldbus_Message *_e_msgbus_core_shutdown_cb(const Eldbus_Service_Interface *iface,
+ const Eldbus_Message *msg);
+
+static Eldbus_Message *_e_msgbus_module_load_cb(const Eldbus_Service_Interface *iface,
+ const Eldbus_Message *msg);
+static Eldbus_Message *_e_msgbus_module_unload_cb(const Eldbus_Service_Interface *iface,
+ const Eldbus_Message *msg);
+static Eldbus_Message *_e_msgbus_module_enable_cb(const Eldbus_Service_Interface *iface,
+ const Eldbus_Message *msg);
+static Eldbus_Message *_e_msgbus_module_disable_cb(const Eldbus_Service_Interface *iface,
+ const Eldbus_Message *msg);
+static Eldbus_Message *_e_msgbus_module_list_cb(const Eldbus_Service_Interface *iface,
+ const Eldbus_Message *msg);
+
+static Eldbus_Message *_e_msgbus_profile_set_cb(const Eldbus_Service_Interface *iface,
+ const Eldbus_Message *msg);
+static Eldbus_Message *_e_msgbus_profile_get_cb(const Eldbus_Service_Interface *iface,
+ const Eldbus_Message *msg);
+static Eldbus_Message *_e_msgbus_profile_list_cb(const Eldbus_Service_Interface *iface,
+ const Eldbus_Message *msg);
+static Eldbus_Message *_e_msgbus_profile_add_cb(const Eldbus_Service_Interface *iface,
+ const Eldbus_Message *msg);
+static Eldbus_Message *_e_msgbus_profile_delete_cb(const Eldbus_Service_Interface *iface,
+ const Eldbus_Message *msg);
#define E_MSGBUS_WIN_ACTION_CB_PROTO(NAME) \
- static EDBus_Message * _e_msgbus_window_##NAME##_cb(const EDBus_Service_Interface * iface, \
- const EDBus_Message * msg)
+ static Eldbus_Message * _e_msgbus_window_##NAME##_cb(const Eldbus_Service_Interface * iface, \
+ const Eldbus_Message * msg)
E_MSGBUS_WIN_ACTION_CB_PROTO(list);
E_MSGBUS_WIN_ACTION_CB_PROTO(close);
@@ -47,64 +47,64 @@ E_MSGBUS_WIN_ACTION_CB_PROTO(unmaximize);
/* local subsystem globals */
static E_Msgbus_Data *_e_msgbus_data = NULL;
-static const EDBus_Method core_methods[] = {
+static const Eldbus_Method core_methods[] = {
{ "Restart", NULL, NULL, _e_msgbus_core_restart_cb },
{ "Shutdown", NULL, NULL, _e_msgbus_core_shutdown_cb },
{ }
};
-static const EDBus_Method module_methods[] = {
- { "Load", EDBUS_ARGS({"s", "module"}), NULL, _e_msgbus_module_load_cb },
- { "Unload", EDBUS_ARGS({"s", "module"}), NULL, _e_msgbus_module_unload_cb },
- { "Enable", EDBUS_ARGS({"s", "module"}), NULL, _e_msgbus_module_enable_cb },
- { "Disable", EDBUS_ARGS({"s", "module"}), NULL, _e_msgbus_module_disable_cb },
- { "List", NULL, EDBUS_ARGS({"a(si)", "modules"}),
+static const Eldbus_Method module_methods[] = {
+ { "Load", ELDBUS_ARGS({"s", "module"}), NULL, _e_msgbus_module_load_cb },
+ { "Unload", ELDBUS_ARGS({"s", "module"}), NULL, _e_msgbus_module_unload_cb },
+ { "Enable", ELDBUS_ARGS({"s", "module"}), NULL, _e_msgbus_module_enable_cb },
+ { "Disable", ELDBUS_ARGS({"s", "module"}), NULL, _e_msgbus_module_disable_cb },
+ { "List", NULL, ELDBUS_ARGS({"a(si)", "modules"}),
_e_msgbus_module_list_cb },
{ }
};
-static const EDBus_Method profile_methods[] = {
- { "Set", EDBUS_ARGS({"s", "profile"}), NULL, _e_msgbus_profile_set_cb },
- { "Get", NULL, EDBUS_ARGS({"s", "profile"}), _e_msgbus_profile_get_cb },
- { "List", NULL, EDBUS_ARGS({"as", "array_profiles"}),
+static const Eldbus_Method profile_methods[] = {
+ { "Set", ELDBUS_ARGS({"s", "profile"}), NULL, _e_msgbus_profile_set_cb },
+ { "Get", NULL, ELDBUS_ARGS({"s", "profile"}), _e_msgbus_profile_get_cb },
+ { "List", NULL, ELDBUS_ARGS({"as", "array_profiles"}),
_e_msgbus_profile_list_cb },
- { "Add", EDBUS_ARGS({"s", "profile"}), NULL, _e_msgbus_profile_add_cb },
- { "Delete", EDBUS_ARGS({"s", "profile"}), NULL, _e_msgbus_profile_delete_cb },
+ { "Add", ELDBUS_ARGS({"s", "profile"}), NULL, _e_msgbus_profile_add_cb },
+ { "Delete", ELDBUS_ARGS({"s", "profile"}), NULL, _e_msgbus_profile_delete_cb },
{ }
};
-static const EDBus_Method window_methods[] = {
- { "List", NULL, EDBUS_ARGS({"a(si)", "array_of_window"}),
+static const Eldbus_Method window_methods[] = {
+ { "List", NULL, ELDBUS_ARGS({"a(si)", "array_of_window"}),
_e_msgbus_window_list_cb },
- { "Close", EDBUS_ARGS({"i", "window_id"}), NULL, _e_msgbus_window_close_cb },
- { "Kill", EDBUS_ARGS({"i", "window_id"}), NULL, _e_msgbus_window_kill_cb },
- { "Focus", EDBUS_ARGS({"i", "window_id"}), NULL, _e_msgbus_window_focus_cb },
- { "Iconify", EDBUS_ARGS({"i", "window_id"}), NULL,
+ { "Close", ELDBUS_ARGS({"i", "window_id"}), NULL, _e_msgbus_window_close_cb },
+ { "Kill", ELDBUS_ARGS({"i", "window_id"}), NULL, _e_msgbus_window_kill_cb },
+ { "Focus", ELDBUS_ARGS({"i", "window_id"}), NULL, _e_msgbus_window_focus_cb },
+ { "Iconify", ELDBUS_ARGS({"i", "window_id"}), NULL,
_e_msgbus_window_iconify_cb },
- { "Uniconify", EDBUS_ARGS({"i", "window_id"}), NULL,
+ { "Uniconify", ELDBUS_ARGS({"i", "window_id"}), NULL,
_e_msgbus_window_uniconify_cb },
- { "Maximize", EDBUS_ARGS({"i", "window_id"}), NULL,
+ { "Maximize", ELDBUS_ARGS({"i", "window_id"}), NULL,
_e_msgbus_window_maximize_cb },
- { "Unmaximize", EDBUS_ARGS({"i", "window_id"}), NULL,
+ { "Unmaximize", ELDBUS_ARGS({"i", "window_id"}), NULL,
_e_msgbus_window_unmaximize_cb },
{ }
};
#define PATH "/org/enlightenment/wm/RemoteObject"
-static const EDBus_Service_Interface_Desc core_desc = {
+static const Eldbus_Service_Interface_Desc core_desc = {
"org.enlightenment.wm.Core", core_methods
};
-static const EDBus_Service_Interface_Desc module_desc = {
+static const Eldbus_Service_Interface_Desc module_desc = {
"org.enlightenment.wm.Module", module_methods
};
-static const EDBus_Service_Interface_Desc profile_desc = {
+static const Eldbus_Service_Interface_Desc profile_desc = {
"org.enlightenment.wm.Profile", profile_methods
};
-static const EDBus_Service_Interface_Desc window_desc = {
+static const Eldbus_Service_Interface_Desc window_desc = {
"org.enlightenment.wm.Window", window_methods
};
@@ -114,21 +114,21 @@ e_msgbus_init(void)
{
_e_msgbus_data = E_NEW(E_Msgbus_Data, 1);
- edbus_init();
+ eldbus_init();
- _e_msgbus_data->conn = edbus_connection_get(EDBUS_CONNECTION_TYPE_SESSION);
+ _e_msgbus_data->conn = eldbus_connection_get(ELDBUS_CONNECTION_TYPE_SESSION);
if (!_e_msgbus_data->conn)
{
- WRN("Cannot get EDBUS_CONNECTION_TYPE_SESSION");
+ WRN("Cannot get ELDBUS_CONNECTION_TYPE_SESSION");
return 0;
}
- _e_msgbus_data->iface = edbus_service_interface_register(_e_msgbus_data->conn,
+ _e_msgbus_data->iface = eldbus_service_interface_register(_e_msgbus_data->conn,
PATH, &core_desc);
- edbus_service_interface_register(_e_msgbus_data->conn, PATH, &module_desc);
- edbus_service_interface_register(_e_msgbus_data->conn, PATH, &profile_desc);
- edbus_service_interface_register(_e_msgbus_data->conn, PATH, &window_desc);
- edbus_name_request(_e_msgbus_data->conn, "org.enlightenment.wm.service",
+ eldbus_service_interface_register(_e_msgbus_data->conn, PATH, &module_desc);
+ eldbus_service_interface_register(_e_msgbus_data->conn, PATH, &profile_desc);
+ eldbus_service_interface_register(_e_msgbus_data->conn, PATH, &window_desc);
+ eldbus_name_request(_e_msgbus_data->conn, "org.enlightenment.wm.service",
0, _e_msgbus_request_name_cb, NULL);
return 1;
}
@@ -137,76 +137,76 @@ EINTERN int
e_msgbus_shutdown(void)
{
if (_e_msgbus_data->iface)
- edbus_service_object_unregister(_e_msgbus_data->iface);
+ eldbus_service_object_unregister(_e_msgbus_data->iface);
if (_e_msgbus_data->conn)
{
- edbus_name_release(_e_msgbus_data->conn,
+ eldbus_name_release(_e_msgbus_data->conn,
"org.enlightenment.wm.service", NULL, NULL);
- edbus_connection_unref(_e_msgbus_data->conn);
+ eldbus_connection_unref(_e_msgbus_data->conn);
}
- edbus_shutdown();
+ eldbus_shutdown();
E_FREE(_e_msgbus_data);
_e_msgbus_data = NULL;
return 1;
}
-EAPI EDBus_Service_Interface *
-e_msgbus_interface_attach(const EDBus_Service_Interface_Desc *desc)
+EAPI Eldbus_Service_Interface *
+e_msgbus_interface_attach(const Eldbus_Service_Interface_Desc *desc)
{
if (!_e_msgbus_data->iface)
return NULL;
- return edbus_service_interface_register(_e_msgbus_data->conn, PATH, desc);
+ return eldbus_service_interface_register(_e_msgbus_data->conn, PATH, desc);
}
static void
-_e_msgbus_request_name_cb(void *data __UNUSED__, const EDBus_Message *msg,
- EDBus_Pending *pending __UNUSED__)
+_e_msgbus_request_name_cb(void *data __UNUSED__, const Eldbus_Message *msg,
+ Eldbus_Pending *pending __UNUSED__)
{
unsigned int flag;
- if (edbus_message_error_get(msg, NULL, NULL))
+ if (eldbus_message_error_get(msg, NULL, NULL))
{
ERR("Could not request bus name");
return;
}
- if (!edbus_message_arguments_get(msg, "u", &flag))
+ if (!eldbus_message_arguments_get(msg, "u", &flag))
{
ERR("Could not get arguments on on_name_request");
return;
}
- if (!(flag & EDBUS_NAME_REQUEST_REPLY_PRIMARY_OWNER))
+ if (!(flag & ELDBUS_NAME_REQUEST_REPLY_PRIMARY_OWNER))
ERR("Name already in use\n");
}
/* Core Handlers */
-static EDBus_Message *
-_e_msgbus_core_restart_cb(const EDBus_Service_Interface *iface __UNUSED__,
- const EDBus_Message *msg)
+static Eldbus_Message *
+_e_msgbus_core_restart_cb(const Eldbus_Service_Interface *iface __UNUSED__,
+ const Eldbus_Message *msg)
{
e_sys_action_do(E_SYS_RESTART, NULL);
- return edbus_message_method_return_new(msg);
+ return eldbus_message_method_return_new(msg);
}
-static EDBus_Message *
-_e_msgbus_core_shutdown_cb(const EDBus_Service_Interface *iface __UNUSED__,
- const EDBus_Message *msg)
+static Eldbus_Message *
+_e_msgbus_core_shutdown_cb(const Eldbus_Service_Interface *iface __UNUSED__,
+ const Eldbus_Message *msg)
{
e_sys_action_do(E_SYS_EXIT, NULL);
- return edbus_message_method_return_new(msg);
+ return eldbus_message_method_return_new(msg);
}
/* Modules Handlers */
-static EDBus_Message *
-_e_msgbus_module_load_cb(const EDBus_Service_Interface *iface __UNUSED__,
- const EDBus_Message *msg)
+static Eldbus_Message *
+_e_msgbus_module_load_cb(const Eldbus_Service_Interface *iface __UNUSED__,
+ const Eldbus_Message *msg)
{
char *module;
- EDBus_Message *reply = edbus_message_method_return_new(msg);
+ Eldbus_Message *reply = eldbus_message_method_return_new(msg);
- if (!edbus_message_arguments_get(msg, "s", &module))
+ if (!eldbus_message_arguments_get(msg, "s", &module))
return reply;
if (!e_module_find(module))
@@ -218,15 +218,15 @@ _e_msgbus_module_load_cb(const EDBus_Service_Interface *iface __UNUSED__,
return reply;
}
-static EDBus_Message *
-_e_msgbus_module_unload_cb(const EDBus_Service_Interface *iface __UNUSED__,
- const EDBus_Message *msg)
+static Eldbus_Message *
+_e_msgbus_module_unload_cb(const Eldbus_Service_Interface *iface __UNUSED__,
+ const Eldbus_Message *msg)
{
char *module;
E_Module *m;
- EDBus_Message *reply = edbus_message_method_return_new(msg);
+ Eldbus_Message *reply = eldbus_message_method_return_new(msg);
- if (!edbus_message_arguments_get(msg, "s", &module))
+ if (!eldbus_message_arguments_get(msg, "s", &module))
return reply;
if ((m = e_module_find(module)))
@@ -239,15 +239,15 @@ _e_msgbus_module_unload_cb(const EDBus_Service_Interface *iface __UNUSED__,
return reply;
}
-static EDBus_Message *
-_e_msgbus_module_enable_cb(const EDBus_Service_Interface *iface __UNUSED__,
- const EDBus_Message *msg)
+static Eldbus_Message *
+_e_msgbus_module_enable_cb(const Eldbus_Service_Interface *iface __UNUSED__,
+ const Eldbus_Message *msg)
{
char *module;
E_Module *m;
- EDBus_Message *reply = edbus_message_method_return_new(msg);
+ Eldbus_Message *reply = eldbus_message_method_return_new(msg);
- if (!edbus_message_arguments_get(msg, "s", &module))
+ if (!eldbus_message_arguments_get(msg, "s", &module))
return reply;
if ((m = e_module_find(module)))
@@ -259,15 +259,15 @@ _e_msgbus_module_enable_cb(const EDBus_Service_Interface *iface __UNUSED__,
return reply;
}
-static EDBus_Message *
-_e_msgbus_module_disable_cb(const EDBus_Service_Interface *iface __UNUSED__,
- const EDBus_Message *msg)
+static Eldbus_Message *
+_e_msgbus_module_disable_cb(const Eldbus_Service_Interface *iface __UNUSED__,
+ const Eldbus_Message *msg)
{
char *module;
E_Module *m;
- EDBus_Message *reply = edbus_message_method_return_new(msg);
+ Eldbus_Message *reply = eldbus_message_method_return_new(msg);
- if (!edbus_message_arguments_get(msg, "s", &module))
+ if (!eldbus_message_arguments_get(msg, "s", &module))
return reply;
if ((m = e_module_find(module)))
@@ -279,50 +279,50 @@ _e_msgbus_module_disable_cb(const EDBus_Service_Interface *iface __UNUSED__,
return reply;
}
-static EDBus_Message *
-_e_msgbus_module_list_cb(const EDBus_Service_Interface *iface __UNUSED__,
- const EDBus_Message *msg)
+static Eldbus_Message *
+_e_msgbus_module_list_cb(const Eldbus_Service_Interface *iface __UNUSED__,
+ const Eldbus_Message *msg)
{
Eina_List *l;
E_Module *mod;
- EDBus_Message *reply = edbus_message_method_return_new(msg);
- EDBus_Message_Iter *main_iter, *array;
+ Eldbus_Message *reply = eldbus_message_method_return_new(msg);
+ Eldbus_Message_Iter *main_iter, *array;
EINA_SAFETY_ON_NULL_RETURN_VAL(reply, NULL);
- main_iter = edbus_message_iter_get(reply);
+ main_iter = eldbus_message_iter_get(reply);
EINA_SAFETY_ON_NULL_RETURN_VAL(main_iter, reply);
- edbus_message_iter_arguments_append(main_iter, "a(si)", &array);
+ eldbus_message_iter_arguments_append(main_iter, "a(si)", &array);
EINA_SAFETY_ON_NULL_RETURN_VAL(array, reply);
EINA_LIST_FOREACH(e_module_list(), l, mod)
{
- EDBus_Message_Iter *s;
+ Eldbus_Message_Iter *s;
const char *name;
int enabled;
name = mod->name;
enabled = mod->enabled;
- edbus_message_iter_arguments_append(array, "(si)", &s);
+ eldbus_message_iter_arguments_append(array, "(si)", &s);
if (!s) continue;
- edbus_message_iter_arguments_append(s, "si", name, enabled);
- edbus_message_iter_container_close(array, s);
+ eldbus_message_iter_arguments_append(s, "si", name, enabled);
+ eldbus_message_iter_container_close(array, s);
}
- edbus_message_iter_container_close(main_iter, array);
+ eldbus_message_iter_container_close(main_iter, array);
return reply;
}
/* Profile Handlers */
-static EDBus_Message *
-_e_msgbus_profile_set_cb(const EDBus_Service_Interface *iface __UNUSED__,
- const EDBus_Message *msg)
+static Eldbus_Message *
+_e_msgbus_profile_set_cb(const Eldbus_Service_Interface *iface __UNUSED__,
+ const Eldbus_Message *msg)
{
char *profile;
- EDBus_Message *reply = edbus_message_method_return_new(msg);
+ Eldbus_Message *reply = eldbus_message_method_return_new(msg);
- if (!edbus_message_arguments_get(msg, "s", &profile))
+ if (!eldbus_message_arguments_get(msg, "s", &profile))
return reply;
e_config_save_flush();
@@ -334,129 +334,129 @@ _e_msgbus_profile_set_cb(const EDBus_Service_Interface *iface __UNUSED__,
return reply;
}
-static EDBus_Message *
-_e_msgbus_profile_get_cb(const EDBus_Service_Interface *iface __UNUSED__,
- const EDBus_Message *msg)
+static Eldbus_Message *
+_e_msgbus_profile_get_cb(const Eldbus_Service_Interface *iface __UNUSED__,
+ const Eldbus_Message *msg)
{
- EDBus_Message *reply = edbus_message_method_return_new(msg);
+ Eldbus_Message *reply = eldbus_message_method_return_new(msg);
const char *profile;
EINA_SAFETY_ON_NULL_RETURN_VAL(reply, NULL);
profile = e_config_profile_get();
- edbus_message_arguments_append(reply, "s", profile);
+ eldbus_message_arguments_append(reply, "s", profile);
return reply;
}
-static EDBus_Message *
-_e_msgbus_profile_list_cb(const EDBus_Service_Interface *iface __UNUSED__,
- const EDBus_Message *msg)
+static Eldbus_Message *
+_e_msgbus_profile_list_cb(const Eldbus_Service_Interface *iface __UNUSED__,
+ const Eldbus_Message *msg)
{
Eina_List *l;
char *name;
- EDBus_Message *reply;
- EDBus_Message_Iter *array, *main_iter;
+ Eldbus_Message *reply;
+ Eldbus_Message_Iter *array, *main_iter;
- reply = edbus_message_method_return_new(msg);
+ reply = eldbus_message_method_return_new(msg);
EINA_SAFETY_ON_NULL_RETURN_VAL(reply, NULL);
- main_iter = edbus_message_iter_get(reply);
+ main_iter = eldbus_message_iter_get(reply);
EINA_SAFETY_ON_FALSE_RETURN_VAL(main_iter, reply);
- edbus_message_iter_arguments_append(main_iter, "as", &array);
+ eldbus_message_iter_arguments_append(main_iter, "as", &array);
EINA_SAFETY_ON_FALSE_RETURN_VAL(array, reply);
l = e_config_profile_list();
EINA_LIST_FREE(l, name)
{
- edbus_message_iter_basic_append(array, 's', name);
+ eldbus_message_iter_basic_append(array, 's', name);
free(name);
}
- edbus_message_iter_container_close(main_iter, array);
+ eldbus_message_iter_container_close(main_iter, array);
return reply;
}
-static EDBus_Message *
-_e_msgbus_profile_add_cb(const EDBus_Service_Interface *iface __UNUSED__,
- const EDBus_Message *msg)
+static Eldbus_Message *
+_e_msgbus_profile_add_cb(const Eldbus_Service_Interface *iface __UNUSED__,
+ const Eldbus_Message *msg)
{
char *profile;
- EDBus_Message *reply = edbus_message_method_return_new(msg);
+ Eldbus_Message *reply = eldbus_message_method_return_new(msg);
- if (!edbus_message_arguments_get(msg, "s", &profile))
+ if (!eldbus_message_arguments_get(msg, "s", &profile))
return reply;
e_config_profile_add(profile);
return reply;
}
-static EDBus_Message *
-_e_msgbus_profile_delete_cb(const EDBus_Service_Interface *iface __UNUSED__,
- const EDBus_Message *msg)
+static Eldbus_Message *
+_e_msgbus_profile_delete_cb(const Eldbus_Service_Interface *iface __UNUSED__,
+ const Eldbus_Message *msg)
{
char *profile;
- if (!edbus_message_arguments_get(msg, "s", &profile))
- return edbus_message_method_return_new(msg);
+ if (!eldbus_message_arguments_get(msg, "s", &profile))
+ return eldbus_message_method_return_new(msg);
if (!strcmp(e_config_profile_get(), profile))
- return edbus_message_error_new(msg,
+ return eldbus_message_error_new(msg,
"org.enlightenment.DBus.InvalidArgument",
"Can't delete active profile");
e_config_profile_del(profile);
- return edbus_message_method_return_new(msg);
+ return eldbus_message_method_return_new(msg);
}
/* Window handlers */
-static EDBus_Message *
-_e_msgbus_window_list_cb(const EDBus_Service_Interface *iface __UNUSED__,
- const EDBus_Message *msg)
+static Eldbus_Message *
+_e_msgbus_window_list_cb(const Eldbus_Service_Interface *iface __UNUSED__,
+ const Eldbus_Message *msg)
{
Eina_List *l;
E_Border *bd;
- EDBus_Message *reply;
- EDBus_Message_Iter *main_iter, *array;
+ Eldbus_Message *reply;
+ Eldbus_Message_Iter *main_iter, *array;
- reply = edbus_message_method_return_new(msg);
+ reply = eldbus_message_method_return_new(msg);
EINA_SAFETY_ON_FALSE_RETURN_VAL(reply, NULL);
- main_iter = edbus_message_iter_get(reply);
+ main_iter = eldbus_message_iter_get(reply);
EINA_SAFETY_ON_FALSE_RETURN_VAL(main_iter, reply);
- edbus_message_iter_arguments_append(main_iter, "a(si)", &array);
+ eldbus_message_iter_arguments_append(main_iter, "a(si)", &array);
EINA_SAFETY_ON_FALSE_RETURN_VAL(array, reply);
EINA_LIST_FOREACH(e_border_client_list(), l, bd)
{
- EDBus_Message_Iter *s;
+ Eldbus_Message_Iter *s;
- edbus_message_iter_arguments_append(array, "(si)", &s);
+ eldbus_message_iter_arguments_append(array, "(si)", &s);
if (!s) continue;
- edbus_message_iter_arguments_append(s, "si", bd->client.icccm.name,
+ eldbus_message_iter_arguments_append(s, "si", bd->client.icccm.name,
bd->client.win);
- edbus_message_iter_container_close(array, s);
+ eldbus_message_iter_container_close(array, s);
}
- edbus_message_iter_container_close(main_iter, array);
+ eldbus_message_iter_container_close(main_iter, array);
return reply;
}
#define E_MSGBUS_WIN_ACTION_CB_BEGIN(NAME) \
- static EDBus_Message * \
- _e_msgbus_window_##NAME##_cb(const EDBus_Service_Interface * iface __UNUSED__, \
- const EDBus_Message * msg) \
+ static Eldbus_Message * \
+ _e_msgbus_window_##NAME##_cb(const Eldbus_Service_Interface * iface __UNUSED__, \
+ const Eldbus_Message * msg) \
{ \
E_Border *bd; \
int xwin; \
\
- if (!edbus_message_arguments_get(msg, "i", &xwin)) \
- return edbus_message_method_return_new(msg); \
+ if (!eldbus_message_arguments_get(msg, "i", &xwin)) \
+ return eldbus_message_method_return_new(msg); \
bd = e_border_find_by_client_window(xwin); \
if (bd) \
{
#define E_MSGBUS_WIN_ACTION_CB_END \
} \
\
- return edbus_message_method_return_new(msg); \
+ return eldbus_message_method_return_new(msg); \
}
E_MSGBUS_WIN_ACTION_CB_BEGIN(close)
diff --git a/src/bin/e_msgbus.h b/src/bin/e_msgbus.h
index 4fe59481a..ae4857217 100644
--- a/src/bin/e_msgbus.h
+++ b/src/bin/e_msgbus.h
@@ -6,17 +6,17 @@ typedef struct _E_Msgbus_Data E_Msgbus_Data;
#ifndef E_MSGBUS_H
#define E_MSGBUS_H
-/* This is the dbus subsystem, but edbus namespace is taken by edbus */
+/* This is the dbus subsystem, but eldbus namespace is taken by eldbus */
struct _E_Msgbus_Data
{
- EDBus_Connection *conn;
- EDBus_Service_Interface *iface;
+ Eldbus_Connection *conn;
+ Eldbus_Service_Interface *iface;
};
EINTERN int e_msgbus_init(void);
EINTERN int e_msgbus_shutdown(void);
-EAPI EDBus_Service_Interface *e_msgbus_interface_attach(const EDBus_Service_Interface_Desc *desc);
+EAPI Eldbus_Service_Interface *e_msgbus_interface_attach(const Eldbus_Service_Interface_Desc *desc);
#endif
#endif
diff --git a/src/bin/e_notification.c b/src/bin/e_notification.c
index acc3dd3c1..756837f1a 100644
--- a/src/bin/e_notification.c
+++ b/src/bin/e_notification.c
@@ -2,8 +2,8 @@
typedef struct _Notification_Data
{
- EDBus_Connection *conn;
- EDBus_Service_Interface *iface;
+ Eldbus_Connection *conn;
+ Eldbus_Service_Interface *iface;
E_Notification_Notify_Cb notify_cb;
E_Notification_Close_Cb close_cb;
void *data;
@@ -13,22 +13,22 @@ typedef struct _Notification_Data
static Notification_Data *n_data = NULL;
static void
-hints_dict_iter(void *data, const void *key, EDBus_Message_Iter *var)
+hints_dict_iter(void *data, const void *key, Eldbus_Message_Iter *var)
{
E_Notification_Notify *n = data;
if (!strcmp(key, "image-data") || !strcmp(key, "image_data"))
{
- EDBus_Message_Iter *st, *data_iter;
+ Eldbus_Message_Iter *st, *data_iter;
int w, h, r, bits, channels;
Eina_Bool alpha;
unsigned char *raw_data;
- if (!edbus_message_iter_arguments_get(var, "(iiibiiay)", &st))
+ if (!eldbus_message_iter_arguments_get(var, "(iiibiiay)", &st))
return;
- if (!edbus_message_iter_arguments_get(st, "iiibiiay", &w, &h, &r,
+ if (!eldbus_message_iter_arguments_get(st, "iiibiiay", &w, &h, &r,
&alpha, &bits, &channels,
&data_iter))
return;
- edbus_message_iter_fixed_array_get(data_iter, 'y', &raw_data,
+ eldbus_message_iter_fixed_array_get(data_iter, 'y', &raw_data,
&n->icon.raw.data_size);
n->icon.raw.width = w;
n->icon.raw.height = h;
@@ -43,23 +43,23 @@ hints_dict_iter(void *data, const void *key, EDBus_Message_Iter *var)
else if (!strcmp(key, "urgency"))
{
unsigned char urgency;
- edbus_message_iter_arguments_get(var, "y", &urgency);
+ eldbus_message_iter_arguments_get(var, "y", &urgency);
if (urgency < 3)
n->urgency = urgency;
}
else if (!strcmp(key, "image-path") || !strcmp(key, "image_path"))
{
- edbus_message_iter_arguments_get(var, "s", &n->icon.icon_path);
+ eldbus_message_iter_arguments_get(var, "s", &n->icon.icon_path);
n->icon.icon_path = eina_stringshare_add(n->icon.icon_path);
}
}
-static EDBus_Message *
-notify_cb(const EDBus_Service_Interface *iface EINA_UNUSED, const EDBus_Message *msg)
+static Eldbus_Message *
+notify_cb(const Eldbus_Service_Interface *iface EINA_UNUSED, const Eldbus_Message *msg)
{
E_Notification_Notify *n;
- EDBus_Message_Iter *actions_iter, *hints_iter;
- EDBus_Message *reply;
+ Eldbus_Message_Iter *actions_iter, *hints_iter;
+ Eldbus_Message *reply;
if (!n_data->notify_cb)
return NULL;
@@ -67,7 +67,7 @@ notify_cb(const EDBus_Service_Interface *iface EINA_UNUSED, const EDBus_Message
n = calloc(1, sizeof(E_Notification_Notify));
EINA_SAFETY_ON_NULL_RETURN_VAL(n, NULL);
- if (!edbus_message_arguments_get(msg, "susssasa{sv}i", &n->app_name,
+ if (!eldbus_message_arguments_get(msg, "susssasa{sv}i", &n->app_name,
&n->replaces_id, &n->icon.icon, &n->sumary,
&n->body, &actions_iter, &hints_iter,
&n->timeout))
@@ -76,66 +76,66 @@ notify_cb(const EDBus_Service_Interface *iface EINA_UNUSED, const EDBus_Message
free(n);
return NULL;
}
- edbus_message_iter_dict_iterate(hints_iter, "sv", hints_dict_iter, n);
+ eldbus_message_iter_dict_iterate(hints_iter, "sv", hints_dict_iter, n);
n->app_name = eina_stringshare_add(n->app_name);
n->icon.icon = eina_stringshare_add(n->icon.icon);
n->sumary = eina_stringshare_add(n->sumary);
n->body = eina_stringshare_add(n->body);
n->id = n_data->notify_cb(n_data->data, n);
- reply = edbus_message_method_return_new(msg);
- edbus_message_arguments_append(reply, "u", n->id);
+ reply = eldbus_message_method_return_new(msg);
+ eldbus_message_arguments_append(reply, "u", n->id);
return reply;
}
-static EDBus_Message *
-close_notification_cb(const EDBus_Service_Interface *iface EINA_UNUSED, const EDBus_Message *msg)
+static Eldbus_Message *
+close_notification_cb(const Eldbus_Service_Interface *iface EINA_UNUSED, const Eldbus_Message *msg)
{
unsigned id;
- if (!edbus_message_arguments_get(msg, "u", &id))
+ if (!eldbus_message_arguments_get(msg, "u", &id))
return NULL;
if (n_data->close_cb)
n_data->close_cb(n_data->data, id);
- return edbus_message_method_return_new(msg);
+ return eldbus_message_method_return_new(msg);
}
-static EDBus_Message *
-capabilities_cb(const EDBus_Service_Interface *iface EINA_UNUSED, const EDBus_Message *msg)
+static Eldbus_Message *
+capabilities_cb(const Eldbus_Service_Interface *iface EINA_UNUSED, const Eldbus_Message *msg)
{
- EDBus_Message *reply = edbus_message_method_return_new(msg);
+ Eldbus_Message *reply = eldbus_message_method_return_new(msg);
int i;
- EDBus_Message_Iter *main_iter, *array;
+ Eldbus_Message_Iter *main_iter, *array;
- main_iter = edbus_message_iter_get(reply);
- edbus_message_iter_arguments_append(main_iter, "as", &array);
+ main_iter = eldbus_message_iter_get(reply);
+ eldbus_message_iter_arguments_append(main_iter, "as", &array);
for (i = 0; n_data->server_info->capabilities[i]; i++)
- edbus_message_iter_arguments_append(array, "s",
+ eldbus_message_iter_arguments_append(array, "s",
n_data->server_info->capabilities[i]);
- edbus_message_iter_container_close(main_iter, array);
+ eldbus_message_iter_container_close(main_iter, array);
return reply;
}
-static EDBus_Message *
-server_info_cb(const EDBus_Service_Interface *iface EINA_UNUSED, const EDBus_Message *msg)
+static Eldbus_Message *
+server_info_cb(const Eldbus_Service_Interface *iface EINA_UNUSED, const Eldbus_Message *msg)
{
- EDBus_Message *reply = edbus_message_method_return_new(msg);
- edbus_message_arguments_append(reply, "ssss", n_data->server_info->name,
+ Eldbus_Message *reply = eldbus_message_method_return_new(msg);
+ eldbus_message_arguments_append(reply, "ssss", n_data->server_info->name,
n_data->server_info->vendor,
n_data->server_info->version,
n_data->server_info->spec_version);
return reply;
}
-static const EDBus_Method methods[] = {
+static const Eldbus_Method methods[] = {
{ "Notify",
- EDBUS_ARGS({"s", "app_name"}, {"u", "replaces_id"}, {"s", "app_icon"}, {"s", "summary"}, {"s", "body"}, {"as", "actions"}, {"a{sv}", "hints"}, {"i", "expire_timeout"}),
- EDBUS_ARGS({"u", "id"}), notify_cb },
- { "CloseNotification", EDBUS_ARGS({"u", "id"}), NULL, close_notification_cb },
- { "GetCapabilities", NULL, EDBUS_ARGS({"as", "capabilities"}),
+ ELDBUS_ARGS({"s", "app_name"}, {"u", "replaces_id"}, {"s", "app_icon"}, {"s", "summary"}, {"s", "body"}, {"as", "actions"}, {"a{sv}", "hints"}, {"i", "expire_timeout"}),
+ ELDBUS_ARGS({"u", "id"}), notify_cb },
+ { "CloseNotification", ELDBUS_ARGS({"u", "id"}), NULL, close_notification_cb },
+ { "GetCapabilities", NULL, ELDBUS_ARGS({"as", "capabilities"}),
capabilities_cb },
{ "GetServerInformation", NULL,
- EDBUS_ARGS({"s", "name"}, {"s", "vendor"}, {"s", "version"}, {"s", "spec_version"}),
+ ELDBUS_ARGS({"s", "name"}, {"s", "vendor"}, {"s", "version"}, {"s", "spec_version"}),
server_info_cb },
{ }
};
@@ -146,11 +146,11 @@ enum
SIGNAL_ACTION_INVOKED,
};
-static const EDBus_Signal signals[] = {
+static const Eldbus_Signal signals[] = {
[SIGNAL_NOTIFICATION_CLOSED] =
- { "NotificationClosed", EDBUS_ARGS({"u", "id"}, {"u", "reason"}) },
+ { "NotificationClosed", ELDBUS_ARGS({"u", "id"}, {"u", "reason"}) },
[SIGNAL_ACTION_INVOKED] =
- { "ActionInvoked", EDBUS_ARGS({"u", "id"}, {"s", "action_key"}) },
+ { "ActionInvoked", ELDBUS_ARGS({"u", "id"}, {"s", "action_key"}) },
{ }
};
@@ -158,7 +158,7 @@ static const EDBus_Signal signals[] = {
#define BUS "org.freedesktop.Notifications"
#define INTERFACE "org.freedesktop.Notifications"
-static const EDBus_Service_Interface_Desc desc = {
+static const Eldbus_Service_Interface_Desc desc = {
INTERFACE, methods, signals, NULL, NULL, NULL
};
@@ -171,15 +171,15 @@ e_notification_server_register(const E_Notification_Server_Info *server_info, E_
n_data = calloc(1, sizeof(Notification_Data));
EINA_SAFETY_ON_NULL_RETURN_VAL(n_data, EINA_FALSE);
- edbus_init();
- n_data->conn = edbus_connection_get(EDBUS_CONNECTION_TYPE_SESSION);
- n_data->iface = edbus_service_interface_register(n_data->conn, PATH, &desc);
+ eldbus_init();
+ n_data->conn = eldbus_connection_get(ELDBUS_CONNECTION_TYPE_SESSION);
+ n_data->iface = eldbus_service_interface_register(n_data->conn, PATH, &desc);
n_data->notify_cb = n_cb;
n_data->close_cb = close_cb;
n_data->data = (void *)data;
n_data->server_info = server_info;
- edbus_name_request(n_data->conn, BUS,
- EDBUS_NAME_REQUEST_FLAG_REPLACE_EXISTING, NULL, NULL);
+ eldbus_name_request(n_data->conn, BUS,
+ ELDBUS_NAME_REQUEST_FLAG_REPLACE_EXISTING, NULL, NULL);
return EINA_TRUE;
}
@@ -188,9 +188,9 @@ EAPI void
e_notification_server_unregister(void)
{
EINA_SAFETY_ON_NULL_RETURN(n_data);
- edbus_service_interface_unregister(n_data->iface);
- edbus_connection_unref(n_data->conn);
- edbus_shutdown();
+ eldbus_service_interface_unregister(n_data->iface);
+ eldbus_connection_unref(n_data->conn);
+ eldbus_shutdown();
free(n_data);
n_data = NULL;
}
@@ -216,7 +216,7 @@ e_notification_notify_close(E_Notification_Notify *notify, E_Notification_Notify
EINA_SAFETY_ON_NULL_RETURN(n_data);
EINA_SAFETY_ON_NULL_RETURN(notify);
EINA_SAFETY_ON_FALSE_RETURN(reason <= E_NOTIFICATION_NOTIFY_CLOSED_REASON_UNDEFINED);
- edbus_service_signal_emit(n_data->iface, SIGNAL_NOTIFICATION_CLOSED,
+ eldbus_service_signal_emit(n_data->iface, SIGNAL_NOTIFICATION_CLOSED,
notify->id, reason);
}
@@ -277,40 +277,40 @@ error:
/* client API */
static void
-client_notify_cb(void *data, const EDBus_Message *msg, EDBus_Pending *pending)
+client_notify_cb(void *data, const Eldbus_Message *msg, Eldbus_Pending *pending)
{
unsigned id = 0;
- E_Notification_Client_Send_Cb cb = edbus_pending_data_del(pending, "cb");
- EDBus_Connection *conn = edbus_pending_data_del(pending, "conn");
- if (edbus_message_error_get(msg, NULL, NULL))
+ E_Notification_Client_Send_Cb cb = eldbus_pending_data_del(pending, "cb");
+ Eldbus_Connection *conn = eldbus_pending_data_del(pending, "conn");
+ if (eldbus_message_error_get(msg, NULL, NULL))
goto end;
- if (!edbus_message_arguments_get(msg, "u", &id))
+ if (!eldbus_message_arguments_get(msg, "u", &id))
goto end;
end:
cb(data, id);
- edbus_connection_unref(conn);
- edbus_shutdown();
+ eldbus_connection_unref(conn);
+ eldbus_shutdown();
}
static Eina_Bool
notification_client_dbus_send(E_Notification_Notify *notify, E_Notification_Client_Send_Cb cb, const void *data)
{
- EDBus_Connection *conn;
- EDBus_Message *msg;
- EDBus_Message_Iter *main_iter, *actions, *hints;
- EDBus_Message_Iter *entry, *var;
- EDBus_Pending *p;
+ Eldbus_Connection *conn;
+ Eldbus_Message *msg;
+ Eldbus_Message_Iter *main_iter, *actions, *hints;
+ Eldbus_Message_Iter *entry, *var;
+ Eldbus_Pending *p;
EINA_SAFETY_ON_NULL_RETURN_VAL(notify, EINA_FALSE);
- edbus_init();
- conn = edbus_connection_get(EDBUS_CONNECTION_TYPE_SESSION);
+ eldbus_init();
+ conn = eldbus_connection_get(ELDBUS_CONNECTION_TYPE_SESSION);
EINA_SAFETY_ON_NULL_RETURN_VAL(conn, EINA_FALSE);
- msg = edbus_message_method_call_new(BUS, PATH, INTERFACE, "Notify");
+ msg = eldbus_message_method_call_new(BUS, PATH, INTERFACE, "Notify");
EINA_SAFETY_ON_NULL_RETURN_VAL(msg, EINA_FALSE);
//build message
- main_iter = edbus_message_iter_get(msg);
- if (!edbus_message_iter_arguments_append(main_iter, "susssas",
+ main_iter = eldbus_message_iter_get(msg);
+ if (!eldbus_message_iter_arguments_append(main_iter, "susssas",
notify->app_name ? : "",
notify->replaces_id,
notify->icon.icon ? : "",
@@ -318,19 +318,19 @@ notification_client_dbus_send(E_Notification_Notify *notify, E_Notification_Clie
notify->body ? : "",
&actions))
goto error;
- edbus_message_iter_container_close(main_iter, actions);
- if (!edbus_message_iter_arguments_append(main_iter, "a{sv}", &hints))
+ eldbus_message_iter_container_close(main_iter, actions);
+ if (!eldbus_message_iter_arguments_append(main_iter, "a{sv}", &hints))
goto error;
if (notify->icon.raw.data)
{
- EDBus_Message_Iter *st, *data_iter;
+ Eldbus_Message_Iter *st, *data_iter;
int i;
- edbus_message_iter_arguments_append(hints, "{sv}", &entry);
- edbus_message_iter_arguments_append(entry, "s", "image-data");
- var = edbus_message_iter_container_new(entry, 'v', "(iiibiiay)");
- edbus_message_iter_arguments_append(var, "(iiibiiay)", &st);
- edbus_message_iter_arguments_append(st, "iiibiiay",
+ eldbus_message_iter_arguments_append(hints, "{sv}", &entry);
+ eldbus_message_iter_arguments_append(entry, "s", "image-data");
+ var = eldbus_message_iter_container_new(entry, 'v', "(iiibiiay)");
+ eldbus_message_iter_arguments_append(var, "(iiibiiay)", &st);
+ eldbus_message_iter_arguments_append(st, "iiibiiay",
notify->icon.raw.width,
notify->icon.raw.height,
notify->icon.raw.rowstride,
@@ -339,42 +339,42 @@ notification_client_dbus_send(E_Notification_Notify *notify, E_Notification_Clie
notify->icon.raw.channels,
&data_iter);
for (i = 0; i < notify->icon.raw.data_size; i++)
- edbus_message_iter_basic_append(data_iter, 'y', notify->icon.raw.data[i]);
- edbus_message_iter_container_close(st, data_iter);
- edbus_message_iter_container_close(var, st);
- edbus_message_iter_container_close(entry, var);
- edbus_message_iter_container_close(hints, entry);
+ eldbus_message_iter_basic_append(data_iter, 'y', notify->icon.raw.data[i]);
+ eldbus_message_iter_container_close(st, data_iter);
+ eldbus_message_iter_container_close(var, st);
+ eldbus_message_iter_container_close(entry, var);
+ eldbus_message_iter_container_close(hints, entry);
}
if (notify->icon.icon_path)
{
- edbus_message_iter_arguments_append(hints, "{sv}", &entry);
- edbus_message_iter_arguments_append(entry, "s", "image-path");
- var = edbus_message_iter_container_new(entry, 'v', "s");
- edbus_message_iter_arguments_append(var, "s", notify->icon.icon_path);
- edbus_message_iter_container_close(entry, var);
- edbus_message_iter_container_close(hints, entry);
+ eldbus_message_iter_arguments_append(hints, "{sv}", &entry);
+ eldbus_message_iter_arguments_append(entry, "s", "image-path");
+ var = eldbus_message_iter_container_new(entry, 'v', "s");
+ eldbus_message_iter_arguments_append(var, "s", notify->icon.icon_path);
+ eldbus_message_iter_container_close(entry, var);
+ eldbus_message_iter_container_close(hints, entry);
}
- edbus_message_iter_arguments_append(hints, "{sv}", &entry);
- edbus_message_iter_arguments_append(entry, "s", "urgency");
- var = edbus_message_iter_container_new(entry, 'v', "y");
- edbus_message_iter_arguments_append(var, "y", notify->urgency);
- edbus_message_iter_container_close(entry, var);
- edbus_message_iter_container_close(hints, entry);
+ eldbus_message_iter_arguments_append(hints, "{sv}", &entry);
+ eldbus_message_iter_arguments_append(entry, "s", "urgency");
+ var = eldbus_message_iter_container_new(entry, 'v', "y");
+ eldbus_message_iter_arguments_append(var, "y", notify->urgency);
+ eldbus_message_iter_container_close(entry, var);
+ eldbus_message_iter_container_close(hints, entry);
- edbus_message_iter_container_close(main_iter, hints);
+ eldbus_message_iter_container_close(main_iter, hints);
- edbus_message_iter_arguments_append(main_iter, "i", notify->timeout);
+ eldbus_message_iter_arguments_append(main_iter, "i", notify->timeout);
- p = edbus_connection_send(conn, msg, client_notify_cb, data, 5000);
+ p = eldbus_connection_send(conn, msg, client_notify_cb, data, 5000);
EINA_SAFETY_ON_NULL_GOTO(p, error);
- edbus_pending_data_set(p, "cb", cb);
- edbus_pending_data_set(p, "conn", conn);
+ eldbus_pending_data_set(p, "cb", cb);
+ eldbus_pending_data_set(p, "conn", conn);
return EINA_TRUE;
error:
- edbus_message_unref(msg);
+ eldbus_message_unref(msg);
return EINA_FALSE;
}
diff --git a/src/bin/e_notification.h b/src/bin/e_notification.h
index 291c2114e..554ecdd13 100644
--- a/src/bin/e_notification.h
+++ b/src/bin/e_notification.h
@@ -1,7 +1,7 @@
#ifndef _E_NOTIFICATION_H
#define _E_NOTIFICATION_H
-#include <EDBus.h>
+#include <Eldbus.h>
#include <Eina.h>
typedef enum _E_Notification_Notify_Urgency