From 14a162c1c42466791a655475289770da076bfd71 Mon Sep 17 00:00:00 2001 From: Marcel Holtmann Date: Mon, 5 Jan 2009 00:32:28 +0100 Subject: [PATCH] Remove scanning support from elements --- include/element.h | 1 - src/element.c | 46 ---------------------------------------------- 2 files changed, 47 deletions(-) diff --git a/include/element.h b/include/element.h index 83c146b..1334a03 100644 --- a/include/element.h +++ b/include/element.h @@ -90,7 +90,6 @@ struct connman_element { enum connman_element_state state; enum connman_element_policy policy; gboolean enabled; - gboolean scanning; gboolean available; gboolean remember; guint16 priority; diff --git a/src/element.c b/src/element.c index aa2d54c..95157dc 100644 --- a/src/element.c +++ b/src/element.c @@ -375,39 +375,6 @@ static void emit_enabled_signal(DBusConnection *conn, g_dbus_send_message(conn, signal); } -static void emit_scanning_signal(DBusConnection *conn, - struct connman_element *element) -{ - DBusMessage *signal; - DBusMessageIter entry, value; - const char *key = "Scanning"; - - DBG("conn %p", conn); - - if (element == NULL) - return; - - if (element->type != CONNMAN_ELEMENT_TYPE_DEVICE) - return; - - signal = dbus_message_new_signal(element->path, - CONNMAN_DEVICE_INTERFACE, "PropertyChanged"); - if (signal == NULL) - return; - - dbus_message_iter_init_append(signal, &entry); - - dbus_message_iter_append_basic(&entry, DBUS_TYPE_STRING, &key); - - dbus_message_iter_open_container(&entry, DBUS_TYPE_VARIANT, - DBUS_TYPE_BOOLEAN_AS_STRING, &value); - dbus_message_iter_append_basic(&value, DBUS_TYPE_BOOLEAN, - &element->scanning); - dbus_message_iter_close_container(&entry, &value); - - g_dbus_send_message(conn, signal); -} - static DBusMessage *do_enable(DBusConnection *conn, DBusMessage *msg, void *data) { @@ -1812,19 +1779,6 @@ int connman_element_set_enabled(struct connman_element *element, return 0; } -int connman_element_set_scanning(struct connman_element *element, - gboolean scanning) -{ - if (element->scanning == scanning) - return 0; - - element->scanning = scanning; - - emit_scanning_signal(connection, element); - - return 0; -} - int __connman_element_init(DBusConnection *conn, const char *device) { struct connman_element *element; -- 2.7.4