From 5366cf41746ee6057036b1c1119a84f3fe80f627 Mon Sep 17 00:00:00 2001 From: Simon McVittie Date: Mon, 10 Mar 2014 18:23:09 +0000 Subject: [PATCH 02/23] Use concrete dbus-glib parameterized types, not G_TYPE_VALUE_ARRAY dbus_g_value_build_g_variant() doesn't yet understand how to build a tuple from a G_TYPE_VALUE_ARRAY, so my branch to use GDBus for everything will rely on using the full parameterized types. --- telepathy-glib/presence-mixin.c | 6 +----- tests/lib/broken-client-types-conn.c | 6 +----- 2 files changed, 2 insertions(+), 10 deletions(-) diff --git a/telepathy-glib/presence-mixin.c b/telepathy-glib/presence-mixin.c index c17dc8a..8b157e3 100644 --- a/telepathy-glib/presence-mixin.c +++ b/telepathy-glib/presence-mixin.c @@ -925,15 +925,11 @@ tp_presence_mixin_fill_contact_attributes (GObject *obj, } else { - G_GNUC_BEGIN_IGNORE_DEPRECATIONS - GType type = G_TYPE_VALUE_ARRAY; - G_GNUC_END_IGNORE_DEPRECATIONS - presence = construct_presence_value_array (status, mixin_cls->statuses); tp_presence_status_free (status); tp_contact_attribute_map_take_sliced_gvalue (attributes, contact, TP_TOKEN_CONNECTION_INTERFACE_PRESENCE1_PRESENCE, - tp_g_value_slice_new_take_boxed (type, presence)); + tp_g_value_slice_new_take_boxed (TP_STRUCT_TYPE_PRESENCE, presence)); } return TRUE; } diff --git a/tests/lib/broken-client-types-conn.c b/tests/lib/broken-client-types-conn.c index 6148f37..7bdc766 100644 --- a/tests/lib/broken-client-types-conn.c +++ b/tests/lib/broken-client-types-conn.c @@ -35,10 +35,6 @@ fill_contact_attributes (TpBaseConnection *base, TpHandle contact, TpContactAttributeMap *attributes) { - G_GNUC_BEGIN_IGNORE_DEPRECATIONS - GType type = G_TYPE_VALUE_ARRAY; - G_GNUC_END_IGNORE_DEPRECATIONS - if (!tp_strdiff (dbus_interface, TP_IFACE_CONNECTION_INTERFACE_CLIENT_TYPES1)) { @@ -52,7 +48,7 @@ fill_contact_attributes (TpBaseConnection *base, tp_contact_attribute_map_take_sliced_gvalue (attributes, contact, TP_TOKEN_CONNECTION_INTERFACE_PRESENCE1_PRESENCE, - tp_g_value_slice_new_take_boxed (type, presence)); + tp_g_value_slice_new_take_boxed (TP_STRUCT_TYPE_PRESENCE, presence)); } } -- 1.9.0