diff options
author | davemds <dave@gurumeditation.it> | 2014-08-23 17:59:22 +0200 |
---|---|---|
committer | davemds <dave@gurumeditation.it> | 2014-08-23 17:59:22 +0200 |
commit | bc02e43181b3c669f89cbed5e942aa5c1be2ebbe (patch) | |
tree | 0a0d03c13b042f73ec33936795024b0c2a8cff73 | |
parent | 1de3ffccd6bd3ff33e6c45fcdc1c181ae904341d (diff) |
Cleanups: the filter are not used here
and the ecore_event is not used enywhere
-rw-r--r-- | efl/dbus_mainloop/e_dbus.c | 49 |
1 files changed, 0 insertions, 49 deletions
diff --git a/efl/dbus_mainloop/e_dbus.c b/efl/dbus_mainloop/e_dbus.c index 730f309..ad45f8b 100644 --- a/efl/dbus_mainloop/e_dbus.c +++ b/efl/dbus_mainloop/e_dbus.c | |||
@@ -30,7 +30,6 @@ static int _e_dbus_log_dom = -1; | |||
30 | #define WARN(...) EINA_LOG_DOM_WARN(_e_dbus_log_dom, __VA_ARGS__) | 30 | #define WARN(...) EINA_LOG_DOM_WARN(_e_dbus_log_dom, __VA_ARGS__) |
31 | #define ERR(...) EINA_LOG_DOM_ERR(_e_dbus_log_dom, __VA_ARGS__) | 31 | #define ERR(...) EINA_LOG_DOM_ERR(_e_dbus_log_dom, __VA_ARGS__) |
32 | 32 | ||
33 | int E_DBUS_EVENT_SIGNAL = 0; | ||
34 | static int connection_slot = -1; | 33 | static int connection_slot = -1; |
35 | static int e_dbus_idler_active = 0; | 34 | static int e_dbus_idler_active = 0; |
36 | static int close_connection = 0; | 35 | static int close_connection = 0; |
@@ -41,50 +40,6 @@ static int _edbus_init_count = 0; | |||
41 | #define DDBG(...) | 40 | #define DDBG(...) |
42 | 41 | ||
43 | 42 | ||
44 | static void | ||
45 | e_dbus_message_free(void *data, void *message) | ||
46 | { | ||
47 | dbus_message_unref(message); | ||
48 | } | ||
49 | |||
50 | static DBusHandlerResult | ||
51 | e_dbus_filter(DBusConnection *conn, DBusMessage *message, void *user_data) | ||
52 | { | ||
53 | E_DBus_Connection *cd = user_data; | ||
54 | DBG("-----------------"); | ||
55 | DBG("Message!"); | ||
56 | |||
57 | DBG("type: %s", dbus_message_type_to_string(dbus_message_get_type(message))); | ||
58 | DBG("path: %s", dbus_message_get_path(message)); | ||
59 | DBG("interface: %s", dbus_message_get_interface(message)); | ||
60 | DBG("member: %s", dbus_message_get_member(message)); | ||
61 | DBG("sender: %s", dbus_message_get_sender(message)); | ||
62 | |||
63 | switch (dbus_message_get_type(message)) | ||
64 | { | ||
65 | case DBUS_MESSAGE_TYPE_METHOD_CALL: | ||
66 | DBG("signature: %s", dbus_message_get_signature(message)); | ||
67 | break; | ||
68 | case DBUS_MESSAGE_TYPE_METHOD_RETURN: | ||
69 | DBG("reply serial %d", dbus_message_get_reply_serial(message)); | ||
70 | break; | ||
71 | case DBUS_MESSAGE_TYPE_ERROR: | ||
72 | DBG("error: %s", dbus_message_get_error_name(message)); | ||
73 | break; | ||
74 | case DBUS_MESSAGE_TYPE_SIGNAL: | ||
75 | dbus_message_ref(message); | ||
76 | if (cd->signal_dispatcher) | ||
77 | cd->signal_dispatcher(cd, message); | ||
78 | ecore_event_add(E_DBUS_EVENT_SIGNAL, message, e_dbus_message_free, NULL); | ||
79 | break; | ||
80 | default: | ||
81 | break; | ||
82 | } | ||
83 | DBG("-----------------"); | ||
84 | |||
85 | return DBUS_HANDLER_RESULT_NOT_YET_HANDLED; | ||
86 | } | ||
87 | |||
88 | static Eina_Bool | 43 | static Eina_Bool |
89 | e_dbus_idler(void *data) | 44 | e_dbus_idler(void *data) |
90 | { | 45 | { |
@@ -457,8 +412,6 @@ e_dbus_init(void) | |||
457 | return --_edbus_init_count; | 412 | return --_edbus_init_count; |
458 | } | 413 | } |
459 | 414 | ||
460 | E_DBUS_EVENT_SIGNAL = ecore_event_type_new(); | ||
461 | |||
462 | return _edbus_init_count; | 415 | return _edbus_init_count; |
463 | } | 416 | } |
464 | 417 | ||
@@ -510,7 +463,6 @@ e_dbus_connection_setup(DBusConnection *conn) | |||
510 | NULL); | 463 | NULL); |
511 | 464 | ||
512 | dbus_connection_set_dispatch_status_function(cd->conn, cb_dispatch_status, cd, NULL); | 465 | dbus_connection_set_dispatch_status_function(cd->conn, cb_dispatch_status, cd, NULL); |
513 | dbus_connection_add_filter(cd->conn, e_dbus_filter, cd, NULL); | ||
514 | cb_dispatch_status(cd->conn, dbus_connection_get_dispatch_status(cd->conn), cd); | 466 | cb_dispatch_status(cd->conn, dbus_connection_get_dispatch_status(cd->conn), cd); |
515 | 467 | ||
516 | return cd; | 468 | return cd; |
@@ -530,7 +482,6 @@ e_dbus_connection_close(E_DBus_Connection *conn) | |||
530 | if (--(conn->refcount) != 0) return; | 482 | if (--(conn->refcount) != 0) return; |
531 | 483 | ||
532 | dbus_connection_free_data_slot(&connection_slot); | 484 | dbus_connection_free_data_slot(&connection_slot); |
533 | dbus_connection_remove_filter(conn->conn, e_dbus_filter, conn); | ||
534 | dbus_connection_set_watch_functions(conn->conn, | 485 | dbus_connection_set_watch_functions(conn->conn, |
535 | NULL, | 486 | NULL, |
536 | NULL, | 487 | NULL, |