[next] telepathy-salut: Aliasing: Implement AliasFlags property
Xavier Claessens
xclaesse at kemper.freedesktop.org
Wed Sep 25 08:28:06 PDT 2013
Module: telepathy-salut
Branch: next
Commit: 0df0ffdd83fccb9b3a0a17fe445d4abc9c273ee0
URL: http://cgit.freedesktop.org/telepathy/telepathy-salut/commit/?id=0df0ffdd83fccb9b3a0a17fe445d4abc9c273ee0
Author: Xavier Claessens <xavier.claessens at collabora.co.uk>
Date: Wed Sep 25 10:27:40 2013 -0400
Aliasing: Implement AliasFlags property
---
src/connection.c | 20 ++++++++++++++++++++
tests/twisted/avahi/aliases.py | 3 +++
2 files changed, 23 insertions(+), 0 deletions(-)
diff --git a/src/connection.c b/src/connection.c
index 9916bd5..d49541b 100644
--- a/src/connection.c
+++ b/src/connection.c
@@ -304,6 +304,21 @@ static TpDBusPropertiesMixinPropImpl conn_avatars_properties[] = {
{ NULL }
};
+static TpDBusPropertiesMixinPropImpl conn_aliasing_properties[] = {
+ { "AliasFlags", GUINT_TO_POINTER (0), NULL },
+ { NULL }
+};
+
+static void
+conn_aliasing_properties_getter (GObject *object,
+ GQuark interface,
+ GQuark name,
+ GValue *value,
+ gpointer getter_data)
+{
+ g_value_set_uint (value, GPOINTER_TO_UINT (getter_data));
+}
+
static void
salut_connection_init (SalutConnection *obj)
{
@@ -763,6 +778,11 @@ salut_connection_class_init (SalutConnectionClass *salut_connection_class)
NULL,
conn_avatars_properties,
},
+ { TP_IFACE_CONNECTION_INTERFACE_ALIASING,
+ conn_aliasing_properties_getter,
+ NULL,
+ conn_aliasing_properties,
+ },
{ NULL }
};
diff --git a/tests/twisted/avahi/aliases.py b/tests/twisted/avahi/aliases.py
index af18ab3..799bd54 100644
--- a/tests/twisted/avahi/aliases.py
+++ b/tests/twisted/avahi/aliases.py
@@ -69,6 +69,9 @@ def test(q, bus, conn):
q.expect('dbus-signal', signal='StatusChanged',
args=[cs.CONN_STATUS_CONNECTED, cs.CSR_NONE_SPECIFIED])
+ flags = conn.Properties.Get(cs.CONN_IFACE_ALIASING, "AliasFlags")
+ assertEquals(flags, 0)
+
assertContains(cs.CONN_IFACE_CONTACT_INFO,
conn.Properties.Get(cs.CONN, "Interfaces"))
ci_props = conn.Properties.GetAll(cs.CONN_IFACE_CONTACT_INFO)
More information about the telepathy-commits
mailing list