Commit ce2218d0 authored by Vitaly Takmazov's avatar Vitaly Takmazov

using boost::signals2 with compatibility for older swiften

parent ee2e261f
......@@ -402,10 +402,6 @@ if (WIN32)
ADD_DEFINITIONS(-DBOOST_THREAD_USE_LIB)
endif()
# We cannot use boost:signals2, because Swiften does not use them,
# for now, just ignore the deprecation warning.
ADD_DEFINITIONS(-DBOOST_SIGNALS_NO_DEPRECATION_WARNING)
if(CMAKE_BUILD_TYPE MATCHES Debug)
if (CMAKE_COMPILER_IS_GNUCXX)
ADD_DEFINITIONS(-O0)
......
......@@ -6,7 +6,6 @@
#include "../TwitterResponseParser.h"
#include "transport/Logging.h"
#include <string>
#include <boost/signals.hpp>
#include <boost/function.hpp>
#include <boost/bind.hpp>
#include <iostream>
......
......@@ -6,7 +6,6 @@
#include "transport/Logging.h"
#include "transport/Config.h"
#include <string>
#include <boost/signals.hpp>
#include <boost/function.hpp>
#include <boost/bind.hpp>
#include <iostream>
......
......@@ -19,7 +19,6 @@
#include "sys/signal.h"
#endif
#include <boost/algorithm/string.hpp>
#include <boost/signal.hpp>
#include <boost/thread.hpp>
#include <boost/thread/mutex.hpp>
......
......@@ -7,7 +7,6 @@
#pragma once
#include <boost/shared_ptr.hpp>
#include <boost/signals.hpp>
#include "Swiften/SwiftenCompat.h"
......@@ -36,7 +35,7 @@ namespace Swift {
virtual void stop();
virtual void cancel();
boost::signal<void (const boost::optional<FileTransferError>&)> onFinished;
SWIFTEN_SIGNAL_NAMESPACE::signal<void (const boost::optional<FileTransferError>&)> onFinished;
private:
void handleStreamInitiationRequestResponse(StreamInitiation::ref, ErrorPayload::ref);
......
......@@ -6,7 +6,6 @@
#include <Swiften/Network/DummyConnectionServer.h>
#include <boost/signal.hpp>
#include <boost/bind.hpp>
#include <boost/system/system_error.hpp>
#include <boost/asio/placeholders.hpp>
......
......@@ -9,7 +9,6 @@
#include <string>
#include <boost/bind.hpp>
#include <boost/foreach.hpp>
#include <boost/signal.hpp>
#include "Swiften/Base/String.h"
#include "Swiften/Network/Connection.h"
......@@ -96,7 +95,7 @@ void Server::stop() {
if (serverFromClientConnectionServer) {
serverFromClientConnectionServer->stop();
BOOST_FOREACH(SWIFTEN_SIGNAL_NAMESPACE::connection& connection, serverFromClientConnectionServerSignalConnections) {
BOOST_FOREACH(SWIFTEN_SIGNAL_CONNECTION_NAMESPACE::connection& connection, serverFromClientConnectionServerSignalConnections) {
connection.disconnect();
}
serverFromClientConnectionServerSignalConnections.clear();
......
......@@ -8,7 +8,6 @@
#include <boost/shared_ptr.hpp>
#include <boost/optional.hpp>
#include <boost/signals2.hpp>
#include <vector>
#include "Swiften/Network/BoostIOServiceThread.h"
......@@ -25,6 +24,7 @@
#include "Swiften/SwiftenCompat.h"
#include <Swiften/TLS/CertificateWithKey.h>
#include <Swiften/Parser/PlatformXMLParserFactory.h>
#include <Swiften/SwiftenCompat.h>
namespace Swift {
class ConnectionServer;
......@@ -59,8 +59,8 @@ namespace Swift {
return serverFromClientConnectionServer;
}
boost::signal<void (const SafeByteArray&)> onDataRead;
boost::signal<void (const SafeByteArray&)> onDataWritten;
SWIFTEN_SIGNAL_NAMESPACE::signal<void (const SafeByteArray&)> onDataRead;
SWIFTEN_SIGNAL_NAMESPACE::signal<void (const SafeByteArray&)> onDataWritten;
void addTLSEncryption(TLSServerContextFactory* tlsContextFactory, CertificateWithKey::ref cert);
......@@ -80,7 +80,7 @@ namespace Swift {
NetworkFactories* networkFactories_;
bool stopping;
SWIFTEN_SHRPTR_NAMESPACE::shared_ptr<ConnectionServer> serverFromClientConnectionServer;
std::vector<SWIFTEN_SIGNAL_NAMESPACE::connection> serverFromClientConnectionServerSignalConnections;
std::vector<SWIFTEN_SIGNAL_CONNECTION_NAMESPACE::connection> serverFromClientConnectionServerSignalConnections;
std::list<SWIFTEN_SHRPTR_NAMESPACE::shared_ptr<ServerFromClientSession> > serverFromClientSessions;
JID selfJID;
StanzaChannel *stanzaChannel_;
......
......@@ -8,7 +8,6 @@
#include <boost/shared_ptr.hpp>
#include <boost/enable_shared_from_this.hpp>
#include <boost/signals.hpp>
#include <string>
#include <Swiften/Session/Session.h>
......@@ -48,7 +47,7 @@ namespace Swift {
Swift::JID remoteJID = Swift::JID());
~ServerFromClientSession();
boost::signal<void ()> onSessionStarted;
SWIFTEN_SIGNAL_NAMESPACE::signal<void ()> onSessionStarted;
void setAllowSASLEXTERNAL();
const std::string &getUser() {
return user_;
......
......@@ -8,7 +8,6 @@
#include <string>
#include <Swiften/Base/SafeByteArray.h>
#include <boost/signal.hpp>
#include "Swiften/Server/ServerFromClientSession.h"
namespace Swift {
......
......@@ -4,8 +4,6 @@
* See Documentation/Licenses/GPLv3.txt for more information.
*/
#include <boost/signals.hpp>
#include "Swiften/Base/SafeByteArray.h"
#include "Swiften/StreamStack/StreamLayer.h"
#include "Swiften/TLS/Certificate.h"
......@@ -37,8 +35,8 @@ namespace Swift {
}
public:
boost::signal<void ()> onError;
boost::signal<void ()> onConnected;
SWIFTEN_SIGNAL_NAMESPACE::signal<void ()> onError;
SWIFTEN_SIGNAL_NAMESPACE::signal<void ()> onConnected;
private:
TLSServerContext* context;
......
......@@ -26,6 +26,7 @@
* Using these it is possible to declare shared pointers and signals like this:
*
* SWIFTEN_SIGNAL_NAMESPACE::signal signal;
* SWIFTEN_SIGNAL_CONNECTION_NAMESPACE::connection &connection;
* SWIFTEN_SHRPTR_NAMESPACE::shared_ptr<Type> ptr;
*
* These are guaranteed to be the same implementation as Swift uses internally,
......@@ -38,11 +39,16 @@
#if (SWIFTEN_VERSION >= 0x040000)
#define SWIFTEN_UNIQUE_PTR std::unique_ptr
#define SWIFTEN_SHRPTR_NAMESPACE std
#include <boost/signals2.hpp>
#define SWIFTEN_SIGNAL_NAMESPACE boost::signals2
#define SWIFTEN_SIGNAL_CONNECTION_NAMESPACE boost::signals2
#define SWIFT_HOSTADDRESS(x) *(Swift::HostAddress::fromString(x))
#else
#define SWIFTEN_UNIQUE_PTR std::auto_ptr
#define SWIFTEN_SHRPTR_NAMESPACE boost
#define SWIFTEN_SIGNAL_NAMESPACE boost::signals
#define BOOST_SIGNALS_NO_DEPRECATION_WARNING
#include <boost/signals.hpp>
#define SWIFTEN_SIGNAL_NAMESPACE boost
#define SWIFTEN_SIGNAL_CONNECTION_NAMESPACE boost::signals
#define SWIFT_HOSTADDRESS(x) Swift::HostAddress(x)
#endif
......@@ -7,12 +7,12 @@
#pragma once
#include <boost/shared_ptr.hpp>
#include <boost/signals.hpp>
#include "Swiften/Base/SafeByteArray.h"
#include "Swiften/TLS/Certificate.h"
#include <Swiften/TLS/CertificateWithKey.h>
#include "Swiften/TLS/CertificateVerificationError.h"
#include "Swiften/SwiftenCompat.h"
namespace Swift {
class PKCS12Certificate;
......@@ -34,9 +34,9 @@ namespace Swift {
virtual ByteArray getFinishMessage() const = 0;
public:
boost::signal<void (const SafeByteArray&)> onDataForNetwork;
boost::signal<void (const SafeByteArray&)> onDataForApplication;
boost::signal<void ()> onError;
boost::signal<void ()> onConnected;
SWIFTEN_SIGNAL_NAMESPACE::signal<void (const SafeByteArray&)> onDataForNetwork;
SWIFTEN_SIGNAL_NAMESPACE::signal<void (const SafeByteArray&)> onDataForApplication;
SWIFTEN_SIGNAL_NAMESPACE::signal<void ()> onError;
SWIFTEN_SIGNAL_NAMESPACE::signal<void ()> onConnected;
};
}
......@@ -26,7 +26,7 @@
#include <boost/algorithm/string.hpp>
#include <boost/assign.hpp>
#include <boost/bind.hpp>
#include <boost/signalslib.hpp>
#include <Swiften/SwiftenCompat.h>
namespace Transport {
......@@ -124,10 +124,10 @@ class Config {
const std::string &getConfigFile() { return m_file; }
/// This signal is emitted when config is loaded/reloaded.
boost::signal<void ()> onConfigReloaded;
SWIFTEN_SIGNAL_NAMESPACE::signal<void ()> onConfigReloaded;
void updateBackendConfig(const std::string &backendConfig);
boost::signal<void ()> onBackendConfigUpdated;
SWIFTEN_SIGNAL_NAMESPACE::signal<void ()> onBackendConfigUpdated;
static Config *createFromArgs(int argc, char **argv, std::string &error, std::string &host, int &port);
......
......@@ -32,8 +32,6 @@
#include "Swiften/Elements/Presence.h"
#include "Swiften/SwiftenCompat.h"
#include <boost/signal.hpp>
namespace Transport {
class Config;
......@@ -98,15 +96,15 @@ class Frontend {
virtual bool isRawXMLEnabled() { return false; }
boost::signal<void (User *, const std::string &name, unsigned int id)> onVCardRequired;
boost::signal<void (User *, SWIFTEN_SHRPTR_NAMESPACE::shared_ptr<Swift::VCard> vcard)> onVCardUpdated;
boost::signal<void (Buddy *, const Swift::RosterItemPayload &item)> onBuddyUpdated;
boost::signal<void (Buddy *)> onBuddyRemoved;
boost::signal<void (Buddy *, const Swift::RosterItemPayload &item)> onBuddyAdded;
boost::signal<void (Swift::Message::ref message)> onMessageReceived;
boost::signal<void (bool /* isAvailable */)> onAvailableChanged;
boost::signal<void (SWIFTEN_SHRPTR_NAMESPACE::shared_ptr<Swift::Presence>) > onPresenceReceived;
boost::signal<void (const Swift::JID& jid, SWIFTEN_SHRPTR_NAMESPACE::shared_ptr<Swift::DiscoInfo> info)> onCapabilitiesReceived;
SWIFTEN_SIGNAL_NAMESPACE::signal<void (User *, const std::string &name, unsigned int id)> onVCardRequired;
SWIFTEN_SIGNAL_NAMESPACE::signal<void (User *, SWIFTEN_SHRPTR_NAMESPACE::shared_ptr<Swift::VCard> vcard)> onVCardUpdated;
SWIFTEN_SIGNAL_NAMESPACE::signal<void (Buddy *, const Swift::RosterItemPayload &item)> onBuddyUpdated;
SWIFTEN_SIGNAL_NAMESPACE::signal<void (Buddy *)> onBuddyRemoved;
SWIFTEN_SIGNAL_NAMESPACE::signal<void (Buddy *, const Swift::RosterItemPayload &item)> onBuddyAdded;
SWIFTEN_SIGNAL_NAMESPACE::signal<void (Swift::Message::ref message)> onMessageReceived;
SWIFTEN_SIGNAL_NAMESPACE::signal<void (bool /* isAvailable */)> onAvailableChanged;
SWIFTEN_SIGNAL_NAMESPACE::signal<void (SWIFTEN_SHRPTR_NAMESPACE::shared_ptr<Swift::Presence>) > onPresenceReceived;
SWIFTEN_SIGNAL_NAMESPACE::signal<void (const Swift::JID& jid, SWIFTEN_SHRPTR_NAMESPACE::shared_ptr<Swift::DiscoInfo> info)> onCapabilitiesReceived;
};
}
......@@ -9,7 +9,7 @@
#include <string.h>
#include "rapidjson/document.h"
#include <boost/signal.hpp>
#include <Swiften/SwiftenCompat.h>
namespace Transport {
......@@ -38,7 +38,7 @@ class HTTPRequest : public Thread {
return m_url;
}
boost::signal<void ()> onRequestFinished;
SWIFTEN_SIGNAL_NAMESPACE::signal<void ()> onRequestFinished;
static void globalInit() {
curl_global_init(CURL_GLOBAL_ALL);
......
......@@ -22,7 +22,6 @@
#include <string>
#include <map>
#include <boost/signal.hpp>
#include "Swiften/FileTransfer/ReadBytestream.h"
#include "Swiften/SwiftenCompat.h"
......@@ -41,7 +40,7 @@ class MemoryReadBytestream : public Swift::ReadBytestream {
void setFinished() { m_finished = true; }
bool isFinished() const;
boost::signal<void ()> onDataNeeded;
SWIFTEN_SIGNAL_NAMESPACE::signal<void ()> onDataNeeded;
private:
bool m_finished;
......
......@@ -22,11 +22,10 @@
#include <map>
#include <boost/signals.hpp>
#include <string>
#include <Swiften/Elements/Presence.h>
#include <Swiften/Client/StanzaChannel.h>
#include <Swiften/SwiftenCompat.h>
namespace Transport {
......@@ -44,7 +43,7 @@ class PresenceOracle {
void clearPresences(const Swift::JID& bareJID);
public:
boost::signal<void (Swift::Presence::ref)> onPresenceChange;
SWIFTEN_SIGNAL_NAMESPACE::signal<void (Swift::Presence::ref)> onPresenceChange;
private:
void handleIncomingPresence(Swift::Presence::ref presence);
......
......@@ -23,7 +23,6 @@
#include <string>
#include <algorithm>
#include <map>
#include <boost/signal.hpp>
#include <boost/pool/pool_alloc.hpp>
#include <boost/pool/object_pool.hpp>
// #include "rosterstorage.h"
......@@ -32,6 +31,7 @@
#include "Swiften/Roster/SetRosterRequest.h"
#include "Swiften/Elements/Presence.h"
#include "Swiften/Network/Timer.h"
#include "Swiften/SwiftenCompat.h"
namespace Transport {
......@@ -94,15 +94,15 @@ class RosterManager {
/// Called when new Buddy is added to this roster.
/// \param buddy newly added Buddy
boost::signal<void (Buddy *buddy)> onBuddySet;
SWIFTEN_SIGNAL_NAMESPACE::signal<void (Buddy *buddy)> onBuddySet;
/// Called when Buddy has been removed from this roster.
/// \param buddy removed Buddy
boost::signal<void (Buddy *buddy)> onBuddyUnset;
SWIFTEN_SIGNAL_NAMESPACE::signal<void (Buddy *buddy)> onBuddyUnset;
boost::signal<void (Buddy *buddy)> onBuddyAdded;
SWIFTEN_SIGNAL_NAMESPACE::signal<void (Buddy *buddy)> onBuddyAdded;
boost::signal<void (Buddy *buddy)> onBuddyRemoved;
SWIFTEN_SIGNAL_NAMESPACE::signal<void (Buddy *buddy)> onBuddyRemoved;
void handleBuddyChanged(Buddy *buddy);
......
......@@ -2,10 +2,10 @@
#include <boost/thread.hpp>
#include <boost/thread/mutex.hpp>
#include <boost/signals2/signal.hpp>
#include <queue>
#include <iostream>
#include "Swiften/EventLoop/EventLoop.h"
#include "Swiften/SwiftenCompat.h"
namespace Transport {
......@@ -56,7 +56,7 @@ class ThreadPool
boost::mutex criticalregion;
Swift::EventLoop *loop;
boost::signals2::signal < void () > onWorkerAvailable;
SWIFTEN_SIGNAL_NAMESPACE::signal < void () > onWorkerAvailable;
public:
ThreadPool(Swift::EventLoop *loop, int maxthreads);
......
......@@ -21,7 +21,6 @@
#pragma once
#include <vector>
#include <boost/signal.hpp>
#include <boost/bind.hpp>
#include "Swiften/Network/BoostTimerFactory.h"
#include "Swiften/Network/BoostIOServiceThread.h"
......@@ -95,10 +94,10 @@ namespace Transport {
/// This signal is emitted when server disconnects the transport because of some error.
/// \param error disconnection error
boost::signal<void (const std::string &error)> onConnectionError;
SWIFTEN_SIGNAL_NAMESPACE::signal<void (const std::string &error)> onConnectionError;
/// This signal is emitted when transport successfully connects the server.
boost::signal<void ()> onConnected;
SWIFTEN_SIGNAL_NAMESPACE::signal<void ()> onConnected;
/// This signal is emitted when XML stanza is sent to server.
......@@ -108,11 +107,11 @@ namespace Transport {
/// (for example to="j2j.domain.tld") and for presences comming to
/// MUC (for example to="#chat%irc.freenode.org@irc.domain.tld")
/// \param presence Presence.
boost::signal<void (Swift::Presence::ref presence)> onUserPresenceReceived;
SWIFTEN_SIGNAL_NAMESPACE::signal<void (Swift::Presence::ref presence)> onUserPresenceReceived;
boost::signal<void (SWIFTEN_SHRPTR_NAMESPACE::shared_ptr<Swift::IQ>)> onRawIQReceived;
SWIFTEN_SIGNAL_NAMESPACE::signal<void (SWIFTEN_SHRPTR_NAMESPACE::shared_ptr<Swift::IQ>)> onRawIQReceived;
boost::signal<void ()> onAdminInterfaceSet;
SWIFTEN_SIGNAL_NAMESPACE::signal<void ()> onAdminInterfaceSet;
void handlePresence(Swift::Presence::ref presence);
void handleConnected();
......
......@@ -20,7 +20,6 @@
#pragma once
#include <boost/signal.hpp>
#include <time.h>
#include "transport/StorageBackend.h"
#include <Swiften/FileTransfer/OutgoingFileTransfer.h>
......@@ -149,12 +148,12 @@ class User {
void leaveRoom(const std::string &room);
boost::signal<void ()> onReadyToConnect;
boost::signal<void (Swift::Presence::ref presence)> onPresenceChanged;
boost::signal<void (Swift::Presence::ref presence)> onRawPresenceReceived;
boost::signal<void (const Swift::JID &who, const std::string &room, const std::string &nickname, const std::string &password)> onRoomJoined;
boost::signal<void (const std::string &room)> onRoomLeft;
boost::signal<void ()> onDisconnected;
SWIFTEN_SIGNAL_NAMESPACE::signal<void ()> onReadyToConnect;
SWIFTEN_SIGNAL_NAMESPACE::signal<void (Swift::Presence::ref presence)> onPresenceChanged;
SWIFTEN_SIGNAL_NAMESPACE::signal<void (Swift::Presence::ref presence)> onRawPresenceReceived;
SWIFTEN_SIGNAL_NAMESPACE::signal<void (const Swift::JID &who, const std::string &room, const std::string &nickname, const std::string &password)> onRoomJoined;
SWIFTEN_SIGNAL_NAMESPACE::signal<void (const std::string &room)> onRoomLeft;
SWIFTEN_SIGNAL_NAMESPACE::signal<void ()> onDisconnected;
private:
void onConnectingTimeout();
......
......@@ -20,7 +20,6 @@
#pragma once
#include <boost/signal.hpp>
#include <string>
#include <map>
#include "Swiften/Elements/Message.h"
......@@ -99,11 +98,11 @@ class UserManager /*: public Swift::EntityCapsProvider*/ {
/// Called when new User class is created.
/// \param user newly created User class
boost::signal<void (User *user)> onUserCreated;
SWIFTEN_SIGNAL_NAMESPACE::signal<void (User *user)> onUserCreated;
/// Called when User class is going to be removed
/// \param user removed User class
boost::signal<void (User *user)> onUserDestroyed;
SWIFTEN_SIGNAL_NAMESPACE::signal<void (User *user)> onUserDestroyed;
/// Returns true if user is connected.
/// \return True if user is connected.
......
......@@ -23,8 +23,8 @@
#include "Swiften/Queries/Responder.h"
#include "Swiften/Elements/InBandRegistrationPayload.h"
#include "Swiften/Elements/RosterPayload.h"
#include <boost/signal.hpp>
#include <Swiften/Version.h>
#include "Swiften/SwiftenCompat.h"
#define HAVE_SWIFTEN_3 (SWIFTEN_VERSION >= 0x030000)
namespace Transport {
......@@ -71,15 +71,15 @@ class UserRegistration {
/// Called when new user has been registered.
/// \param userInfo UserInfo struct with informations about user
boost::signal<void (const UserInfo &userInfo)> onUserRegistered;
SWIFTEN_SIGNAL_NAMESPACE::signal<void (const UserInfo &userInfo)> onUserRegistered;
/// Called when user has been unregistered.
/// \param userInfo UserInfo struct with informations about user
boost::signal<void (const UserInfo &userInfo)> onUserUnregistered;
SWIFTEN_SIGNAL_NAMESPACE::signal<void (const UserInfo &userInfo)> onUserUnregistered;
/// Called when user's registration has been updated.
/// \param userInfo UserInfo struct with informations about user
boost::signal<void (const UserInfo &userInfo)> onUserUpdated;
SWIFTEN_SIGNAL_NAMESPACE::signal<void (const UserInfo &userInfo)> onUserUpdated;
private:
Component *m_component;
......
......@@ -96,10 +96,10 @@ class UserRegistry : public Swift::UserRegistry {
const std::string getUserPassword(const std::string &barejid);
/// Emitted when user wants to connect legacy network to validate the password.
boost::signal<void (const Swift::JID &user)> onConnectUser;
SWIFTEN_SIGNAL_NAMESPACE::signal<void (const Swift::JID &user)> onConnectUser;
/// Emitted when user disconnected XMPP server and therefore should disconnect legacy network.
boost::signal<void (const Swift::JID &user)> onDisconnectUser;
SWIFTEN_SIGNAL_NAMESPACE::signal<void (const Swift::JID &user)> onDisconnectUser;
private:
typedef struct {
......
......@@ -43,8 +43,6 @@
#include <algorithm>
#include <map>
#include <boost/signal.hpp>
namespace Transport {
class Component;
......@@ -60,10 +58,10 @@ class WebSocketClient {
void write(const std::string &data);
boost::signal<void (const std::string &payload)> onPayloadReceived;
SWIFTEN_SIGNAL_NAMESPACE::signal<void (const std::string &payload)> onPayloadReceived;
boost::signal<void ()> onWebSocketConnected;
boost::signal<void (const boost::optional<Swift::Connection::Error> &error)> onWebSocketDisconnected;
SWIFTEN_SIGNAL_NAMESPACE::signal<void ()> onWebSocketConnected;
SWIFTEN_SIGNAL_NAMESPACE::signal<void (const boost::optional<Swift::Connection::Error> &error)> onWebSocketDisconnected;
private:
void handleDNSResult(const std::vector<Swift::HostAddress>&, boost::optional<Swift::DomainNameResolveError>);
......
......@@ -48,7 +48,6 @@
#include "Swiften/Elements/SpectrumErrorPayload.h"
#include "boost/date_time/posix_time/posix_time.hpp"
#include "boost/signal.hpp"
#include "transport/utf8.h"
......@@ -87,7 +86,7 @@ class NetworkConversation : public Conversation {
onMessageToSend(this, message);
}
boost::signal<void (NetworkConversation *, SWIFTEN_SHRPTR_NAMESPACE::shared_ptr<Swift::Message> &)> onMessageToSend;
SWIFTEN_SIGNAL_NAMESPACE::signal<void (NetworkConversation *, SWIFTEN_SHRPTR_NAMESPACE::shared_ptr<Swift::Message> &)> onMessageToSend;
};
class NetworkFactory : public Factory {
......
......@@ -28,8 +28,6 @@
#include <algorithm>
#include <map>
#include <boost/signal.hpp>
namespace Transport {
class Component;
......
......@@ -47,8 +47,6 @@
#include <algorithm>
#include <map>
#include <boost/signal.hpp>
namespace Transport {
class SlackIdManager {
......
......@@ -47,8 +47,6 @@
#include <algorithm>
#include <map>
#include <boost/signal.hpp>
namespace Transport {
class Component;
......@@ -70,13 +68,13 @@ class SlackRTM {
void sendMessage(const std::string &channel, const std::string &message);
boost::signal<void ()> onRTMStarted;
SWIFTEN_SIGNAL_NAMESPACE::signal<void ()> onRTMStarted;
SlackAPI *getAPI() {
return m_api;
}
boost::signal<void (const std::string &channel, const std::string &user, const std::string &text, const std::string &ts)> onMessageReceived;
SWIFTEN_SIGNAL_NAMESPACE::signal<void (const std::string &channel, const std::string &user, const std::string &text, const std::string &ts)> onMessageReceived;
#ifndef LIBTRANSPORT_TEST
private:
......
......@@ -31,8 +31,6 @@
#include "Swiften/Network/Timer.h"
#include "Swiften/SwiftenCompat.h"
#include <boost/signal.hpp>
namespace Transport {
class Component;
......@@ -49,7 +47,7 @@ class SlackSession {
virtual ~SlackSession();
boost::signal<void (const std::string &user)> onInstallationDone;
SWIFTEN_SIGNAL_NAMESPACE::signal<void (const std::string &user)> onInstallationDone;
void sendMessage(SWIFTEN_SHRPTR_NAMESPACE::shared_ptr<Swift::Message> message);
......
......@@ -22,8 +22,6 @@
#include "transport/UserRegistration.h"