diff options
author | Guillaume Desmottes <guillaume.desmottes@collabora.co.uk> | 2007-10-25 09:10:34 +0000 |
---|---|---|
committer | Guillaume Desmottes <guillaume.desmottes@collabora.co.uk> | 2007-10-25 09:10:34 +0000 |
commit | f41aa253fd224853340169cd63c55103f0c2a7c3 (patch) | |
tree | bb993d6e53b1de8932d18caa7284c7dcda0778a9 /src | |
parent | ace98cb4e13fb5ae6fbecd91f700704214d9bc10 (diff) | |
download | telepathy-salut-f41aa253fd224853340169cd63c55103f0c2a7c3.tar.gz |
use gibber_muc_connection_new_stream to allocate the stream used with D-Bus tubes
20071025091034-7fe3f-61dd210e04e0131b7f6a7606e301e78b2d4ff966.gz
Diffstat (limited to 'src')
-rw-r--r-- | src/salut-tubes-channel.c | 3 | ||||
-rw-r--r-- | src/tube-dbus.c | 13 | ||||
-rw-r--r-- | src/tube-dbus.h | 4 |
3 files changed, 7 insertions, 13 deletions
diff --git a/src/salut-tubes-channel.c b/src/salut-tubes-channel.c index 54a0f65c..b75f4e8d 100644 --- a/src/salut-tubes-channel.c +++ b/src/salut-tubes-channel.c @@ -833,6 +833,7 @@ create_new_tube (SalutTubesChannel *self, TpHandle initiator, const gchar *service, GHashTable *parameters, + /* TODO: remove the stream_id param */ const gchar *stream_id, guint tube_id, GibberBytestreamIface *bytestream) @@ -850,7 +851,7 @@ create_new_tube (SalutTubesChannel *self, case TP_TUBE_TYPE_DBUS: tube = SALUT_TUBE_IFACE (salut_tube_dbus_new (priv->conn, priv->handle, priv->handle_type, priv->self_handle, muc_connection, - initiator, service, parameters, stream_id, tube_id, bytestream)); + initiator, service, parameters, tube_id, bytestream)); break; /* case TP_TUBE_TYPE_STREAM_UNIX: diff --git a/src/tube-dbus.c b/src/tube-dbus.c index 7572fc01..99d0c7d3 100644 --- a/src/tube-dbus.c +++ b/src/tube-dbus.c @@ -576,10 +576,6 @@ salut_tube_dbus_set_property (GObject *object, G_CALLBACK (bytestream_state_changed_cb), self); } break; - case PROP_STREAM_ID: - g_free (priv->stream_id); - priv->stream_id = g_value_dup_string (value); - break; case PROP_INITIATOR: priv->initiator = g_value_get_uint (value); break; @@ -638,7 +634,6 @@ salut_tube_dbus_constructor (GType type, const gchar *peer_id; g_assert (priv->muc_connection != NULL); - g_assert (priv->stream_id != NULL); priv->dbus_names = g_hash_table_new_full (g_direct_hash, g_direct_equal, NULL, g_free); @@ -661,12 +656,13 @@ salut_tube_dbus_constructor (GType type, bytestream = g_object_new (GIBBER_TYPE_BYTESTREAM_MUC, "muc-connection", priv->muc_connection, - "stream-id", priv->stream_id, "state", state, "self-id", priv->conn->name, "peer-id", peer_id, NULL); + g_object_get (bytestream, "stream-id", &priv->stream_id, NULL); + g_object_set (self, "bytestream", bytestream, NULL); } else @@ -753,8 +749,7 @@ salut_tube_dbus_class_init (SalutTubeDBusClass *salut_tube_dbus_class) "stream id", "The identifier of this tube's bytestream", "", - G_PARAM_CONSTRUCT_ONLY | - G_PARAM_READWRITE | + G_PARAM_READABLE | G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB); @@ -1024,7 +1019,6 @@ salut_tube_dbus_new (SalutConnection *conn, TpHandle initiator, const gchar *service, GHashTable *parameters, - const gchar *stream_id, guint id, GibberBytestreamIface *bytestream) { @@ -1037,7 +1031,6 @@ salut_tube_dbus_new (SalutConnection *conn, "initiator", initiator, "service", service, "parameters", parameters, - "stream-id", stream_id, "id", id, NULL); diff --git a/src/tube-dbus.h b/src/tube-dbus.h index ad6c46a4..cf12bb4c 100644 --- a/src/tube-dbus.h +++ b/src/tube-dbus.h @@ -63,8 +63,8 @@ SalutTubeDBus * salut_tube_dbus_new (SalutConnection *conn, TpHandle handle, TpHandleType handle_type, TpHandle self_handle, GibberMucConnection *muc_connection, TpHandle initiator, - const gchar *service, GHashTable *parameters, const gchar *stream_id, - guint id, GibberBytestreamIface *bytestream); + const gchar *service, GHashTable *parameters, guint id, + GibberBytestreamIface *bytestream); gboolean salut_tube_dbus_add_name (SalutTubeDBus *self, TpHandle handle, const gchar *name); |