From 952ff645038946b98d3ffe99b4bf4754bbbcc9b0 Mon Sep 17 00:00:00 2001 From: Jeremy Lainé Date: Fri, 10 Sep 2010 10:28:14 +0000 Subject: let extensions report their features --- src/QXmppOutgoingClient.cpp | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'src/QXmppOutgoingClient.cpp') diff --git a/src/QXmppOutgoingClient.cpp b/src/QXmppOutgoingClient.cpp index cc225e5a..1f1bb331 100644 --- a/src/QXmppOutgoingClient.cpp +++ b/src/QXmppOutgoingClient.cpp @@ -74,6 +74,9 @@ public: QAbstractSocket::SocketError socketError; QXmppStanza::Error::Condition xmppStreamError; + // Discovery + QStringList extraFeatures; + // State data QString bindId; QString sessionId; @@ -803,6 +806,11 @@ QXmppStanza::Error::Condition QXmppOutgoingClient::xmppStreamError() return d->xmppStreamError; } +void QXmppOutgoingClient::addFeatures(const QStringList &features) +{ + d->extraFeatures << features; +} + QXmppDiscoveryIq QXmppOutgoingClient::capabilities() const { QXmppDiscoveryIq iq; @@ -818,7 +826,6 @@ QXmppDiscoveryIq QXmppOutgoingClient::capabilities() const << ns_vcard // XEP-0054: vcard-temp << ns_bytestreams // XEP-0065: SOCKS5 Bytestreams << ns_chat_states // XEP-0085: Chat State Notifications - << ns_version // XEP-0092: Software Version << ns_stream_initiation // XEP-0095: Stream Initiation << ns_stream_initiation_file_transfer // XEP-0096: SI File Transfer << ns_capabilities // XEP-0115 : Entity Capabilities @@ -827,6 +834,7 @@ QXmppDiscoveryIq QXmppOutgoingClient::capabilities() const << ns_jingle_rtp_audio << ns_jingle_ice_udp // XEP-0176 : Jingle ICE-UDP Transport Method << ns_ping; // XEP-0199: XMPP Ping + features << d->extraFeatures; iq.setFeatures(features); // identities -- cgit v1.2.3