diff options
author | Tobias Markmann <tm@ayena.de> | 2016-04-05 13:17:19 (GMT) |
---|---|---|
committer | Tobias Markmann <tm@ayena.de> | 2016-04-05 19:42:39 (GMT) |
commit | 2b560b129b7a31fc8cc07f618e763c95a22bf832 (patch) | |
tree | 73e72cdc758b79d01485dc28dcedd48b26859ae8 /Swift/Controllers/XMPPEvents | |
parent | 3c560e31b0f168da917e8d566db01fd1cd997d86 (diff) | |
download | swift-2b560b129b7a31fc8cc07f618e763c95a22bf832.zip swift-2b560b129b7a31fc8cc07f618e763c95a22bf832.tar.bz2 |
Migrate to Boost.Signals2 from Boost.Signals
Boost.Signals was deprecated and is not improved further.
This patch removes Boost.Signals from 3rdParty and adds
Boost.Signals2 and its dependencies.
Also removed the Qt signals compatibility file
Swiften/Base/boost_bsignals.h.
Test-Information:
Build and ran unit tests on OS X 10.11.4. Confirmed successful
login using Swift client.
Change-Id: Ie6e3b2d15aac2462cda95401582f5287a479fb54
Diffstat (limited to 'Swift/Controllers/XMPPEvents')
-rw-r--r-- | Swift/Controllers/XMPPEvents/ErrorEvent.h | 3 | ||||
-rw-r--r-- | Swift/Controllers/XMPPEvents/EventController.h | 6 | ||||
-rw-r--r-- | Swift/Controllers/XMPPEvents/StanzaEvent.h | 5 | ||||
-rw-r--r-- | Swift/Controllers/XMPPEvents/SubscriptionRequestEvent.h | 7 |
4 files changed, 11 insertions, 10 deletions
diff --git a/Swift/Controllers/XMPPEvents/ErrorEvent.h b/Swift/Controllers/XMPPEvents/ErrorEvent.h index f3888cb..c0b5e52 100644 --- a/Swift/Controllers/XMPPEvents/ErrorEvent.h +++ b/Swift/Controllers/XMPPEvents/ErrorEvent.h @@ -10,7 +10,8 @@ #include <memory> #include <string> -#include <Swiften/Base/boost_bsignals.h> +#include <boost/signals2.hpp> + #include <Swiften/JID/JID.h> #include <Swift/Controllers/XMPPEvents/StanzaEvent.h> diff --git a/Swift/Controllers/XMPPEvents/EventController.h b/Swift/Controllers/XMPPEvents/EventController.h index 1e198cb..8a095d9 100644 --- a/Swift/Controllers/XMPPEvents/EventController.h +++ b/Swift/Controllers/XMPPEvents/EventController.h @@ -9,7 +9,7 @@ #include <memory> #include <vector> -#include <Swiften/Base/boost_bsignals.h> +#include <boost/signals2.hpp> #include <Swift/Controllers/XMPPEvents/MessageEvent.h> #include <Swift/Controllers/XMPPEvents/StanzaEvent.h> @@ -22,8 +22,8 @@ namespace Swift { ~EventController(); void handleIncomingEvent(std::shared_ptr<StanzaEvent> sourceEvent); - boost::signal<void (int)> onEventQueueLengthChange; - boost::signal<void (std::shared_ptr<StanzaEvent>)> onEventQueueEventAdded; + boost::signals2::signal<void (int)> onEventQueueLengthChange; + boost::signals2::signal<void (std::shared_ptr<StanzaEvent>)> onEventQueueEventAdded; const EventList& getEvents() const {return events_;} void disconnectAll(); void clear(); diff --git a/Swift/Controllers/XMPPEvents/StanzaEvent.h b/Swift/Controllers/XMPPEvents/StanzaEvent.h index 0ddcdbe..56c4ea3 100644 --- a/Swift/Controllers/XMPPEvents/StanzaEvent.h +++ b/Swift/Controllers/XMPPEvents/StanzaEvent.h @@ -9,8 +9,7 @@ #include <memory> #include <boost/date_time/posix_time/posix_time.hpp> - -#include <Swiften/Base/boost_bsignals.h> +#include <boost/signals2.hpp> namespace Swift { class StanzaEvent { @@ -20,7 +19,7 @@ namespace Swift { void conclude() {concluded_ = true; onConclusion();} /** Do not call this directly from outside the class. * If you connect to this signal, you *must* disconnect from it manually. */ - boost::signal<void()> onConclusion; + boost::signals2::signal<void()> onConclusion; bool getConcluded() {return concluded_;} boost::posix_time::ptime getTime() {return time_;} private: diff --git a/Swift/Controllers/XMPPEvents/SubscriptionRequestEvent.h b/Swift/Controllers/XMPPEvents/SubscriptionRequestEvent.h index 85d3722..8e3fd32 100644 --- a/Swift/Controllers/XMPPEvents/SubscriptionRequestEvent.h +++ b/Swift/Controllers/XMPPEvents/SubscriptionRequestEvent.h @@ -10,7 +10,8 @@ #include <memory> #include <string> -#include <Swiften/Base/boost_bsignals.h> +#include <boost/signals2.hpp> + #include <Swiften/JID/JID.h> #include <Swift/Controllers/XMPPEvents/StanzaEvent.h> @@ -22,8 +23,8 @@ namespace Swift { virtual ~SubscriptionRequestEvent(){} const JID& getJID() const {return jid_;} const std::string& getReason() const {return reason_;} - boost::signal<void()> onAccept; - boost::signal<void()> onDecline; + boost::signals2::signal<void()> onAccept; + boost::signals2::signal<void()> onDecline; void accept() { onAccept(); conclude(); |