}
}
-static void technology_enabled(enum connman_device_type type,
- connman_bool_t enabled)
+static void technology_registered(enum connman_service_type type,
+ connman_bool_t registered)
{
- GSList *list;
DBusMessage *signal;
DBusMessageIter entry, value, iter;
- const char *key = "EnabledTechnologies";
+ const char *key = "AvailableTechnologies";
- DBG("type %d enabled %d", type, enabled);
+ DBG("type %d registered %d", type, registered);
signal = dbus_message_new_signal(CONNMAN_MANAGER_PATH,
CONNMAN_MANAGER_INTERFACE, "PropertyChanged");
if (signal == NULL)
- goto done;
+ return;
dbus_message_iter_init_append(signal, &entry);
dbus_message_iter_close_container(&entry, &value);
g_dbus_send_message(connection, signal);
-
-done:
- for (list = notifier_list; list; list = list->next) {
- struct connman_notifier *notifier = list->data;
-
- if (notifier->device_enabled)
- notifier->device_enabled(type, enabled);
- }
}
-static void technology_registered(enum connman_service_type type,
- connman_bool_t registered)
+static void technology_enabled(enum connman_device_type type,
+ connman_bool_t enabled)
{
+ GSList *list;
DBusMessage *signal;
DBusMessageIter entry, value, iter;
- const char *key = "AvailableTechnologies";
+ const char *key = "EnabledTechnologies";
- DBG("type %d registered %d", type, registered);
+ DBG("type %d enabled %d", type, enabled);
signal = dbus_message_new_signal(CONNMAN_MANAGER_PATH,
CONNMAN_MANAGER_INTERFACE, "PropertyChanged");
if (signal == NULL)
- return;
+ goto done;
dbus_message_iter_init_append(signal, &entry);
dbus_message_iter_close_container(&entry, &value);
g_dbus_send_message(connection, signal);
+
+done:
+ for (list = notifier_list; list; list = list->next) {
+ struct connman_notifier *notifier = list->data;
+
+ if (notifier->device_enabled)
+ notifier->device_enabled(type, enabled);
+ }
}
static void technology_connected(enum connman_service_type type,