[gnome-online-accounts/wip/rishi/introspect] examples: List the name of the GoaProviders
- From: Debarshi Ray <debarshir src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-online-accounts/wip/rishi/introspect] examples: List the name of the GoaProviders
- Date: Mon, 1 Aug 2016 10:57:20 +0000 (UTC)
commit 0c1e4a7c264fe658019f7dd432cb87ba77927ca4
Author: Debarshi Ray <debarshir gnome org>
Date: Mon Aug 1 12:55:57 2016 +0200
examples: List the name of the GoaProviders
src/examples/introspect-providers.c | 5 +++++
1 files changed, 5 insertions(+), 0 deletions(-)
---
diff --git a/src/examples/introspect-providers.c b/src/examples/introspect-providers.c
index c39f5d6..5adc346 100644
--- a/src/examples/introspect-providers.c
+++ b/src/examples/introspect-providers.c
@@ -108,6 +108,7 @@ get_all (GObject *source_object, GAsyncResult *res, gpointer user_data)
GoaProviderFeatures features;
const gchar *type;
gchar *group;
+ gchar *name;
guint i;
features = goa_provider_get_provider_features (provider);
@@ -117,6 +118,9 @@ get_all (GObject *source_object, GAsyncResult *res, gpointer user_data)
type = goa_provider_get_provider_type (provider);
group = g_strconcat ("Provider ", type, NULL);
+ name = goa_provider_get_name (provider);
+ g_key_file_set_string (key_file, group, "ProviderName", name);
+
for (i = 0; provider_features_info[i].key != NULL; i++)
{
if ((features & provider_features_info[i].feature) != 0)
@@ -134,6 +138,7 @@ get_all (GObject *source_object, GAsyncResult *res, gpointer user_data)
}
g_free (group);
+ g_free (name);
}
error = NULL;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]