[telepathy-gabble/master] NewConnection has been renamed NewRemoteConnection

Guillaume Desmottes guillaume.desmottes at collabora.co.uk
Tue May 19 09:03:04 PDT 2009


---
 src/tube-stream.c                                |   11 ++++++-----
 tests/twisted/tubes/offer-muc-stream-tube.py     |    4 ++--
 tests/twisted/tubes/offer-private-stream-tube.py |    8 ++++----
 3 files changed, 12 insertions(+), 11 deletions(-)

diff --git a/src/tube-stream.c b/src/tube-stream.c
index e0afd15..a48faa0 100644
--- a/src/tube-stream.c
+++ b/src/tube-stream.c
@@ -800,7 +800,7 @@ transport_connected_data_free (transport_connected_data *data)
 }
 
 static void
-fire_new_connection (GabbleTubeStream *self,
+fire_new_remote_connection (GabbleTubeStream *self,
     GibberTransport *transport,
     TpHandle contact)
 {
@@ -832,8 +832,9 @@ fire_new_connection (GabbleTubeStream *self,
     }
 
   /* fire NewConnection D-Bus signal */
-  gabble_svc_channel_type_stream_tube_emit_new_connection (self,
-      contact, &access_control_param);
+  /* FIXME: set the right ID of the connection */
+  gabble_svc_channel_type_stream_tube_emit_new_remote_connection (self,
+      contact, &access_control_param, 0);
   g_value_unset (&access_control_param);
 }
 
@@ -841,7 +842,7 @@ static void
 transport_connected_cb (GibberTransport *transport,
     transport_connected_data *data)
 {
-  fire_new_connection (data->self, transport, data->contact);
+  fire_new_remote_connection (data->self, transport, data->contact);
 }
 
 static GibberTransport *
@@ -1894,7 +1895,7 @@ gabble_tube_stream_add_bytestream (GabbleTubeIface *tube,
 
       if (gibber_transport_get_state (transport) == GIBBER_TRANSPORT_CONNECTED)
         {
-          fire_new_connection (self, transport, contact);
+          fire_new_remote_connection (self, transport, contact);
         }
       else
         {
diff --git a/tests/twisted/tubes/offer-muc-stream-tube.py b/tests/twisted/tubes/offer-muc-stream-tube.py
index 01fdeab..f0cd2b0 100644
--- a/tests/twisted/tubes/offer-muc-stream-tube.py
+++ b/tests/twisted/tubes/offer-muc-stream-tube.py
@@ -319,10 +319,10 @@ def test(q, bus, conn, stream, bytestream_cls,
     iq_event, socket_event, conn_event = q.expect_many(
         EventPattern('stream-iq', iq_type='result'),
         EventPattern('socket-connected'),
-        EventPattern('dbus-signal', signal='NewConnection',
+        EventPattern('dbus-signal', signal='NewRemoteConnection',
             interface=cs.CHANNEL_TYPE_STREAM_TUBE))
 
-    handle, access = conn_event.args
+    handle, access, id = conn_event.args
     assert handle == bob_handle
 
     protocol = socket_event.protocol
diff --git a/tests/twisted/tubes/offer-private-stream-tube.py b/tests/twisted/tubes/offer-private-stream-tube.py
index 7e75aa5..21718d8 100644
--- a/tests/twisted/tubes/offer-private-stream-tube.py
+++ b/tests/twisted/tubes/offer-private-stream-tube.py
@@ -332,7 +332,7 @@ def test(q, bus, conn, stream, bytestream_cls,
                 args=[stream_tube_id, cs.TUBE_STATE_OPEN]),
             EventPattern('dbus-signal', signal='StreamTubeNewConnection',
                 args=[stream_tube_id, bob_handle]),
-            EventPattern('dbus-signal', signal='NewConnection'),
+            EventPattern('dbus-signal', signal='NewRemoteConnection'),
             EventPattern('socket-connected'))
 
     bytestream1.check_si_reply(si_reply_event.stanza)
@@ -340,7 +340,7 @@ def test(q, bus, conn, stream, bytestream_cls,
         si_reply_event.stanza)
     assert len(tube) == 1
 
-    handle, access = new_conn_event.args
+    handle, access, id = new_conn_event.args
     assert handle == bob_handle
     protocol = socket_event.protocol
     # we don't want to echo the access control byte
@@ -370,7 +370,7 @@ def test(q, bus, conn, stream, bytestream_cls,
             EventPattern('stream-iq', iq_type='result'),
             EventPattern('dbus-signal', signal='TubeChannelStateChanged',
                 args=[cs.TUBE_STATE_OPEN]),
-            EventPattern('dbus-signal', signal='NewConnection'),
+            EventPattern('dbus-signal', signal='NewRemoteConnection'),
             EventPattern('socket-connected'))
 
     bytestream2.check_si_reply(si_reply_event.stanza)
@@ -378,7 +378,7 @@ def test(q, bus, conn, stream, bytestream_cls,
         si_reply_event.stanza)
     assert len(tube) == 1
 
-    handle, access = new_conn_event.args
+    handle, access, id = new_conn_event.args
     assert handle == bob_handle
     protocol = socket_event.protocol
     # we don't want to echo the access control byte
-- 
1.5.6.5




More information about the telepathy-commits mailing list