summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'Swiften/ScreenSharing')
-rw-r--r--Swiften/ScreenSharing/IncomingScreenSharing.cpp62
-rw-r--r--Swiften/ScreenSharing/IncomingScreenSharing.h19
-rw-r--r--Swiften/ScreenSharing/IncomingScreenSharingManager.cpp7
-rw-r--r--Swiften/ScreenSharing/IncomingScreenSharingManager.h6
-rw-r--r--Swiften/ScreenSharing/InputEventResponder.cpp30
-rw-r--r--Swiften/ScreenSharing/InputEventResponder.h29
-rw-r--r--Swiften/ScreenSharing/OutgoingScreenSharing.cpp9
-rw-r--r--Swiften/ScreenSharing/OutgoingScreenSharing.h7
-rw-r--r--Swiften/ScreenSharing/OutgoingScreenSharingManager.cpp6
-rw-r--r--Swiften/ScreenSharing/OutgoingScreenSharingManager.h2
-rw-r--r--Swiften/ScreenSharing/SConscript1
-rw-r--r--Swiften/ScreenSharing/ScreenSharingManager.h4
-rw-r--r--Swiften/ScreenSharing/ScreenSharingManagerImpl.cpp28
-rw-r--r--Swiften/ScreenSharing/ScreenSharingManagerImpl.h11
14 files changed, 194 insertions, 27 deletions
diff --git a/Swiften/ScreenSharing/IncomingScreenSharing.cpp b/Swiften/ScreenSharing/IncomingScreenSharing.cpp
index 15574c4..fbd4b16 100644
--- a/Swiften/ScreenSharing/IncomingScreenSharing.cpp
+++ b/Swiften/ScreenSharing/IncomingScreenSharing.cpp
@@ -11,24 +11,33 @@
#include <Swiften/Elements/JingleRTPDescription.h>
#include <Swiften/Network/UDPSocketFactory.h>
#include <Swiften/Network/UDPSocket.h>
+#include <Swiften/Network/TimerFactory.h>
+#include <Swiften/Network/Timer.h>
#include <Swiften/ScreenSharing/RTPSessionImpl.h>
#include <Swiften/ScreenSharing/VP8Decoder.h>
#include <Swiften/ScreenSharing/VP8RTPParser.h>
+#include <Swiften/Queries/Request.h>
+#include <Swiften/Queries/GenericRequest.h>
+#include <Swiften/Base/FloatCompare.h>
#include <boost/bind.hpp>
namespace Swift {
IncomingScreenSharing::IncomingScreenSharing(boost::shared_ptr<JingleSession> session, UDPSocketFactory* udpSocketFactory,
- boost::shared_ptr<JingleContentPayload> content)
+ TimerFactory* timerFactory, IQRouter* iqRouter, boost::shared_ptr<JingleContentPayload> content)
: ScreenSharing(session, udpSocketFactory),
- initialContent(content), parser(0), decoder(0)
+ initialContent(content), parser(0), decoder(0), lastMouveMoveEvent(InputEventPayload::Event::MouseMove),
+ inputEventPayload(boost::make_shared<InputEventPayload>()), eventSendingTimer(timerFactory->createTimer(500)),
+ iqRouter(iqRouter)
{
onStateChange(ScreenSharing::WaitingForAccept);
+ eventSendingTimer->onTick.connect(boost::bind(&IncomingScreenSharing::handleEventSendingTimerTick, this));
}
IncomingScreenSharing::~IncomingScreenSharing()
{
+ eventSendingTimer->onTick.disconnect(boost::bind(&IncomingScreenSharing::handleEventSendingTimerTick, this));
delete rtpSession;
delete parser;
delete decoder;
@@ -73,7 +82,7 @@ void IncomingScreenSharing::accept()
decoder = new VP8Decoder;
parser = new VP8RTPParser(decoder);
rtpSession->onIncomingPacket.connect(boost::bind(&VP8RTPParser::newPayloadReceived, parser, _1, _2, _3));
- decoder->onNewImageDecoded.connect(boost::bind(&IncomingScreenSharing::hangleNewImageDecoded, this, _1));
+ decoder->onNewImageDecoded.connect(boost::bind(&IncomingScreenSharing::handleNewImageDecoded, this, _1));
}
onStateChange(ScreenSharing::Connecting);
@@ -84,15 +93,60 @@ const JID &IncomingScreenSharing::getSender() const
return jingleSession->getInitiator();
}
+void IncomingScreenSharing::sendInputEvent(const InputEventPayload::Event& event)
+{
+ if (event.type == InputEventPayload::Event::Unknown)
+ return;
+
+ if (inputEventPayload->getEvents().empty()) {
+ eventSendingTimer->start();
+ }
+ if (event.type == InputEventPayload::Event::MouseMove) {
+ lastMouveMoveEvent.realArg1 = event.realArg1;
+ lastMouveMoveEvent.realArg2 = event.realArg2;
+ } else {
+ addLastMouseMoveIfDifferent();
+ inputEventPayload->addEvent(event);
+ }
+}
+
JingleContentID IncomingScreenSharing::getContentID() const
{
return JingleContentID(initialContent->getName(), initialContent->getCreator());
}
-void IncomingScreenSharing::hangleNewImageDecoded(const Image& image)
+void IncomingScreenSharing::handleNewImageDecoded(const Image& image)
{
onStateChange(ScreenSharing::Receiving);
onNewImageReceived(image);
}
+void IncomingScreenSharing::handleEventSendingTimerTick()
+{
+ addLastMouseMoveIfDifferent();
+ boost::shared_ptr< GenericRequest<InputEventPayload> > request
+ = boost::make_shared< GenericRequest<InputEventPayload> >(IQ::Set, getSender(), inputEventPayload, iqRouter);
+ request->send();
+ // Prepare for a new payload
+ inputEventPayload.reset(new InputEventPayload);
+}
+
+void IncomingScreenSharing::addLastMouseMoveIfDifferent()
+{
+ const std::vector<InputEventPayload::Event>& events = inputEventPayload->getEvents();
+ std::vector<InputEventPayload::Event>::const_reverse_iterator last;
+ std::vector<InputEventPayload::Event>::const_reverse_iterator it;
+ for (it = events.rbegin(); it != events.rend(); ++it) {
+ if (it->type == InputEventPayload::Event::MouseMove) {
+ last = it;
+ break;
+ }
+ }
+ if (it == events.rend()
+ || !approximatelyEqual(it->realArg1, lastMouveMoveEvent.realArg1)
+ || !approximatelyEqual(it->realArg2, lastMouveMoveEvent.realArg2)) {
+ inputEventPayload->addEvent(lastMouveMoveEvent);
+ }
+}
+
}
diff --git a/Swiften/ScreenSharing/IncomingScreenSharing.h b/Swiften/ScreenSharing/IncomingScreenSharing.h
index cc25a9f..c46a6f8 100644
--- a/Swiften/ScreenSharing/IncomingScreenSharing.h
+++ b/Swiften/ScreenSharing/IncomingScreenSharing.h
@@ -11,11 +11,17 @@
#include <Swiften/Elements/RTPPayloadType.h>
#include <Swiften/Base/boost_bsignals.h>
+#include <Swiften/Elements/InputEventPayload.h>
+
+
namespace Swift {
class JingleContentPayload;
class VP8RTPParser;
class VideoDecoder;
class Image;
+ class TimerFactory;
+ class Timer;
+ class IQRouter;
class IncomingScreenSharing : public ScreenSharing {
public:
@@ -23,26 +29,33 @@ namespace Swift {
public:
IncomingScreenSharing(boost::shared_ptr<JingleSession> jingleSession, UDPSocketFactory* udpSocketFactory,
- boost::shared_ptr<JingleContentPayload> content);
+ TimerFactory* timerFactory, IQRouter* iqRouter, boost::shared_ptr<JingleContentPayload> content);
virtual ~IncomingScreenSharing();
virtual void cancel();
-
void accept();
const JID& getSender() const;
+ void sendInputEvent(const InputEventPayload::Event& event);
+
public:
boost::signal<void (const Image&)> onNewImageReceived;
private:
JingleContentID getContentID() const;
- void hangleNewImageDecoded(const Image& image);
+ void handleNewImageDecoded(const Image& image);
+ void handleEventSendingTimerTick();
+ void addLastMouseMoveIfDifferent();
private:
boost::shared_ptr<JingleContentPayload> initialContent;
RTPPayloadType payloadTypeUsed;
VP8RTPParser* parser;
VideoDecoder* decoder;
+ InputEventPayload::Event lastMouveMoveEvent;
+ InputEventPayload::ref inputEventPayload;
+ boost::shared_ptr<Timer> eventSendingTimer;
+ IQRouter* iqRouter;
};
}
diff --git a/Swiften/ScreenSharing/IncomingScreenSharingManager.cpp b/Swiften/ScreenSharing/IncomingScreenSharingManager.cpp
index 321ab4c..8557f40 100644
--- a/Swiften/ScreenSharing/IncomingScreenSharingManager.cpp
+++ b/Swiften/ScreenSharing/IncomingScreenSharingManager.cpp
@@ -15,8 +15,9 @@
namespace Swift {
-IncomingScreenSharingManager::IncomingScreenSharingManager(JingleSessionManager* jingleSessionManager, IQRouter* router, UDPSocketFactory* udpSocketFactory)
- : jingleSessionManager(jingleSessionManager), router(router), udpSocketFactory(udpSocketFactory)
+IncomingScreenSharingManager::IncomingScreenSharingManager(JingleSessionManager* jingleSessionManager, IQRouter* iqRouter,
+ UDPSocketFactory* udpSocketFactory, TimerFactory* timerFactory)
+ : jingleSessionManager(jingleSessionManager), iqRouter(iqRouter), udpSocketFactory(udpSocketFactory), timerFactory(timerFactory)
{
jingleSessionManager->addIncomingSessionHandler(this);
}
@@ -36,7 +37,7 @@ bool IncomingScreenSharingManager::handleIncomingJingleSession(Swift::JingleSess
// Check description
// Create IncomingScreenSharing
- onIncomingScreenSharing(boost::make_shared<IncomingScreenSharing>(session, udpSocketFactory, content));
+ onIncomingScreenSharing(boost::make_shared<IncomingScreenSharing>(session, udpSocketFactory, timerFactory, iqRouter, content));
return true;
}
diff --git a/Swiften/ScreenSharing/IncomingScreenSharingManager.h b/Swiften/ScreenSharing/IncomingScreenSharingManager.h
index 3563a87..586cb0b 100644
--- a/Swiften/ScreenSharing/IncomingScreenSharingManager.h
+++ b/Swiften/ScreenSharing/IncomingScreenSharingManager.h
@@ -13,10 +13,11 @@ namespace Swift {
class IQRouter;
class JingleSessionManager;
class UDPSocketFactory;
+ class TimerFactory;
class IncomingScreenSharingManager : public IncomingJingleSessionHandler {
public:
- IncomingScreenSharingManager(JingleSessionManager* jingleSessionManager, IQRouter* router, UDPSocketFactory* udpSocketFactory);
+ IncomingScreenSharingManager(JingleSessionManager* jingleSessionManager, IQRouter* iqRouter, UDPSocketFactory* udpSocketFactory, TimerFactory* timerFactory);
virtual ~IncomingScreenSharingManager();
public:
@@ -27,7 +28,8 @@ namespace Swift {
private:
JingleSessionManager* jingleSessionManager;
- IQRouter* router;
+ IQRouter* iqRouter;
UDPSocketFactory *udpSocketFactory;
+ TimerFactory* timerFactory;
};
}
diff --git a/Swiften/ScreenSharing/InputEventResponder.cpp b/Swiften/ScreenSharing/InputEventResponder.cpp
new file mode 100644
index 0000000..ce9a541
--- /dev/null
+++ b/Swiften/ScreenSharing/InputEventResponder.cpp
@@ -0,0 +1,30 @@
+/*
+ * Copyright (c) 2012 Yoann Blein
+ * Licensed under the simplified BSD license.
+ * See Documentation/Licenses/BSD-simplified.txt for more information.
+ */
+
+#include <Swiften/ScreenSharing/InputEventResponder.h>
+#include <Swiften/ScreenSharing/ScreenSharingManager.h>
+
+namespace Swift {
+
+InputEventResponder::InputEventResponder(ScreenSharingManager* ssManager, IQRouter* router)
+ : SetResponder<InputEventPayload>(router), ssManager(ssManager)
+{
+}
+
+InputEventResponder::~InputEventResponder()
+{
+}
+
+bool InputEventResponder::handleSetRequest(const JID& from, const JID&, const std::string& id, boost::shared_ptr<InputEventPayload> payload)
+{
+ if (payload->getAction() == InputEventPayload::Notify) {
+ sendResponse(from, id, boost::shared_ptr<InputEventPayload>());
+ ssManager->handleInputEvent(from, payload);
+ }
+ return true;
+}
+
+}
diff --git a/Swiften/ScreenSharing/InputEventResponder.h b/Swiften/ScreenSharing/InputEventResponder.h
new file mode 100644
index 0000000..6d1acd3
--- /dev/null
+++ b/Swiften/ScreenSharing/InputEventResponder.h
@@ -0,0 +1,29 @@
+/*
+ * Copyright (c) 2012 Yoann Blein
+ * Licensed under the simplified BSD license.
+ * See Documentation/Licenses/BSD-simplified.txt for more information.
+ */
+
+#pragma once
+
+#include <Swiften/Queries/SetResponder.h>
+#include <Swiften/Elements/InputEventPayload.h>
+
+namespace Swift {
+ class IQRouter;
+ class JingleSessionManager;
+ class ScreenSharingManager;
+
+ class InputEventResponder : public SetResponder<InputEventPayload> {
+ public:
+ InputEventResponder(ScreenSharingManager* ssManager, IQRouter* router);
+ virtual ~InputEventResponder();
+
+ private:
+ virtual bool handleSetRequest(const JID& from, const JID&, const std::string& id, boost::shared_ptr<InputEventPayload> payload);
+
+ private:
+ ScreenSharingManager* ssManager;
+ IQRouter* router;
+ };
+}
diff --git a/Swiften/ScreenSharing/OutgoingScreenSharing.cpp b/Swiften/ScreenSharing/OutgoingScreenSharing.cpp
index 7cea50e..363b23c 100644
--- a/Swiften/ScreenSharing/OutgoingScreenSharing.cpp
+++ b/Swiften/ScreenSharing/OutgoingScreenSharing.cpp
@@ -23,9 +23,9 @@
namespace Swift {
-OutgoingScreenSharing::OutgoingScreenSharing(boost::shared_ptr<JingleSession> session, UDPSocketFactory* udpSocketFactory, TimerFactory* timerFactory)
+OutgoingScreenSharing::OutgoingScreenSharing(boost::shared_ptr<JingleSession> session, UDPSocketFactory* udpSocketFactory, TimerFactory* timerFactory, const JID &toJID)
: ScreenSharing(session, udpSocketFactory),
- timerFactory(timerFactory), contentID(JingleContentID(idGenerator.generateID(), JingleContentPayload::InitiatorCreator)),
+ timerFactory(timerFactory), recipient(toJID), contentID(JingleContentID(idGenerator.generateID(), JingleContentPayload::InitiatorCreator)),
canceled(false), sessionAccepted(false), socketConnected(false), encoder(0), packetizer(0)
{
jingleSession->onSessionAcceptReceived.connect(boost::bind(&OutgoingScreenSharing::handleSessionAcceptReceived, this, _1, _2, _3));
@@ -76,6 +76,11 @@ void OutgoingScreenSharing::addImage(const Image &image)
encoder->encodeImage(image);
}
+const JID& OutgoingScreenSharing::getRecipient() const
+{
+ return recipient;
+}
+
void OutgoingScreenSharing::handleSocketConnected()
{
if (canceled)
diff --git a/Swiften/ScreenSharing/OutgoingScreenSharing.h b/Swiften/ScreenSharing/OutgoingScreenSharing.h
index cacc715..245d038 100644
--- a/Swiften/ScreenSharing/OutgoingScreenSharing.h
+++ b/Swiften/ScreenSharing/OutgoingScreenSharing.h
@@ -22,13 +22,14 @@ namespace Swift {
class VideoEncoder;
class VP8RTPPacketizer;
class Image;
+ class InputEventPayload;
class OutgoingScreenSharing : public ScreenSharing {
public:
typedef boost::shared_ptr<OutgoingScreenSharing> ref;
public:
- OutgoingScreenSharing(boost::shared_ptr<JingleSession> jingleSession, UDPSocketFactory* udpSocketFactory, TimerFactory* timerFactory);
+ OutgoingScreenSharing(boost::shared_ptr<JingleSession> jingleSession, UDPSocketFactory* udpSocketFactory, TimerFactory* timerFactory, const JID& recipient);
virtual ~OutgoingScreenSharing();
virtual void cancel();
@@ -36,8 +37,11 @@ namespace Swift {
void start(unsigned int width, unsigned int height);
void addImage(const Image& image);
+ const JID& getRecipient() const;
+
public:
boost::signal<void ()> onReady;
+ boost::signal<void (boost::shared_ptr<InputEventPayload>)> onNewInputEvent;
private:
void handleSocketConnected();
@@ -48,6 +52,7 @@ namespace Swift {
private:
TimerFactory* timerFactory;
+ JID recipient;
JingleContentID contentID;
bool canceled;
bool sessionAccepted;
diff --git a/Swiften/ScreenSharing/OutgoingScreenSharingManager.cpp b/Swiften/ScreenSharing/OutgoingScreenSharingManager.cpp
index aaa2198..872fd19 100644
--- a/Swiften/ScreenSharing/OutgoingScreenSharingManager.cpp
+++ b/Swiften/ScreenSharing/OutgoingScreenSharingManager.cpp
@@ -19,13 +19,13 @@ OutgoingScreenSharingManager::OutgoingScreenSharingManager(JingleSessionManager*
{
}
-boost::shared_ptr<OutgoingScreenSharing> OutgoingScreenSharingManager::createOutgoingScreenSharing(const JID& from, const JID& to)
+boost::shared_ptr<OutgoingScreenSharing> OutgoingScreenSharingManager::createOutgoingScreenSharing(const JID& from, const JID& recipient)
{
- JingleSessionImpl::ref jingleSession = boost::make_shared<JingleSessionImpl>(from, to, idGenerator.generateID(), iqRouter);
+ JingleSessionImpl::ref jingleSession = boost::make_shared<JingleSessionImpl>(from, recipient, idGenerator.generateID(), iqRouter);
assert(jingleSession);
jsManager->registerOutgoingSession(from, jingleSession);
- return boost::make_shared<OutgoingScreenSharing>(jingleSession, udpSocketFactory, timerFactory);
+ return boost::make_shared<OutgoingScreenSharing>(jingleSession, udpSocketFactory, timerFactory, recipient);
}
}
diff --git a/Swiften/ScreenSharing/OutgoingScreenSharingManager.h b/Swiften/ScreenSharing/OutgoingScreenSharingManager.h
index de21d5a..56888ba 100644
--- a/Swiften/ScreenSharing/OutgoingScreenSharingManager.h
+++ b/Swiften/ScreenSharing/OutgoingScreenSharingManager.h
@@ -22,7 +22,7 @@ namespace Swift {
OutgoingScreenSharingManager(JingleSessionManager* jingleSessionManager, IQRouter* router,
UDPSocketFactory* udpSocketFactory, TimerFactory* timerFactory);
- boost::shared_ptr<OutgoingScreenSharing> createOutgoingScreenSharing(const JID& from, const JID& to);
+ boost::shared_ptr<OutgoingScreenSharing> createOutgoingScreenSharing(const JID& from, const JID& recipient);
private:
IDGenerator idGenerator;
diff --git a/Swiften/ScreenSharing/SConscript b/Swiften/ScreenSharing/SConscript
index 1eeb443..aefe45b 100644
--- a/Swiften/ScreenSharing/SConscript
+++ b/Swiften/ScreenSharing/SConscript
@@ -9,6 +9,7 @@ sources = [
"IncomingScreenSharingManager.cpp",
"ScreenSharingManagerImpl.cpp",
"VP8RTPParser.cpp",
+ "InputEventResponder.cpp",
]
objects = swiften_env.SwiftenObject(sources)
diff --git a/Swiften/ScreenSharing/ScreenSharingManager.h b/Swiften/ScreenSharing/ScreenSharingManager.h
index a527402..6a97146 100644
--- a/Swiften/ScreenSharing/ScreenSharingManager.h
+++ b/Swiften/ScreenSharing/ScreenSharingManager.h
@@ -14,6 +14,7 @@ namespace Swift {
class IncomingScreenSharing;
class OutgoingScreenSharing;
class JID;
+ class InputEventPayload;
class ScreenSharingManager {
public:
@@ -21,6 +22,9 @@ namespace Swift {
virtual boost::shared_ptr<OutgoingScreenSharing> createOutgoingScreenSharing(const JID& to) = 0;
+ virtual void handleInputEvent(const JID& from, boost::shared_ptr<InputEventPayload> payload) = 0;
+
+ public:
boost::signal<void (boost::shared_ptr<IncomingScreenSharing>)> onIncomingScreenSharing;
};
}
diff --git a/Swiften/ScreenSharing/ScreenSharingManagerImpl.cpp b/Swiften/ScreenSharing/ScreenSharingManagerImpl.cpp
index b0e337a..c20d2c7 100644
--- a/Swiften/ScreenSharing/ScreenSharingManagerImpl.cpp
+++ b/Swiften/ScreenSharing/ScreenSharingManagerImpl.cpp
@@ -12,22 +12,33 @@
#include <Swiften/Presence/PresenceOracle.h>
#include <Swiften/ScreenSharing/IncomingScreenSharingManager.h>
#include <Swiften/ScreenSharing/OutgoingScreenSharingManager.h>
+#include <Swiften/ScreenSharing/OutgoingScreenSharing.h>
+#include <Swiften/ScreenSharing/InputEventResponder.h>
+
+#include <boost/foreach.hpp>
namespace Swift {
ScreenSharingManagerImpl::ScreenSharingManagerImpl(const JID& ownFullJID, JingleSessionManager *jingleSessionManager, IQRouter *iqRouter,
UDPSocketFactory* udpSocketFactory, TimerFactory* timerFactory, PresenceOracle* presenceOrable,
EntityCapsProvider* capsProvider)
- : ownJID(ownFullJID)/*, jingleSM(jingleSessionManager), iqRouter(iqRouter), udpSocketFactory(udpSocketFactory), timerFactory(timerFactory)*/, capsProvider(capsProvider), presenceOracle(presenceOrable)
+ : ownJID(ownFullJID), capsProvider(capsProvider), presenceOracle(presenceOrable)
{
- incomingSSManager = new IncomingScreenSharingManager(jingleSessionManager, iqRouter, udpSocketFactory);
+ incomingSSManager = new IncomingScreenSharingManager(jingleSessionManager, iqRouter, udpSocketFactory, timerFactory);
outgoingSSManager = new OutgoingScreenSharingManager(jingleSessionManager, iqRouter, udpSocketFactory, timerFactory);
+ responder = new InputEventResponder(this, iqRouter);
+ responder->start();
+
incomingSSManager->onIncomingScreenSharing.connect(onIncomingScreenSharing);
}
ScreenSharingManagerImpl::~ScreenSharingManagerImpl()
{
+ responder->stop();
+ delete responder;
+ delete incomingSSManager;
+ delete outgoingSSManager;
}
boost::shared_ptr<OutgoingScreenSharing> ScreenSharingManagerImpl::createOutgoingScreenSharing(const JID &to)
@@ -43,7 +54,18 @@ boost::shared_ptr<OutgoingScreenSharing> ScreenSharingManagerImpl::createOutgoin
}
}
- return outgoingSSManager->createOutgoingScreenSharing(ownJID, recipient);
+ OutgoingScreenSharing::ref oss = outgoingSSManager->createOutgoingScreenSharing(ownJID, recipient);
+ outgoingSharings.push_back(oss);
+ return oss;
+}
+
+void ScreenSharingManagerImpl::handleInputEvent(const JID& from, boost::shared_ptr<InputEventPayload> payload)
+{
+ foreach (OutgoingScreenSharing::ref oss, outgoingSharings) {
+ if (oss->getRecipient() == from) {
+ oss->onNewInputEvent(payload);
+ }
+ }
}
boost::optional<JID> ScreenSharingManagerImpl::highestPriorityJIDSupportingScreenSharing(const JID& bareJID) {
diff --git a/Swiften/ScreenSharing/ScreenSharingManagerImpl.h b/Swiften/ScreenSharing/ScreenSharingManagerImpl.h
index 8e8ea78..8f73f87 100644
--- a/Swiften/ScreenSharing/ScreenSharingManagerImpl.h
+++ b/Swiften/ScreenSharing/ScreenSharingManagerImpl.h
@@ -18,6 +18,8 @@ namespace Swift {
class TimerFactory;
class PresenceOracle;
class EntityCapsProvider;
+ class InputEventResponder;
+ class InputEventPayload;
class ScreenSharingManagerImpl : public ScreenSharingManager {
public:
@@ -28,19 +30,18 @@ namespace Swift {
virtual boost::shared_ptr<OutgoingScreenSharing> createOutgoingScreenSharing(const JID& to);
+ virtual void handleInputEvent(const JID& from, boost::shared_ptr<InputEventPayload> payload);
+
private:
boost::optional<JID> highestPriorityJIDSupportingScreenSharing(const JID &bareJID);
private:
IncomingScreenSharingManager* incomingSSManager;
OutgoingScreenSharingManager* outgoingSSManager;
-
+ InputEventResponder* responder;
JID ownJID;
+ std::vector< boost::shared_ptr<OutgoingScreenSharing> > outgoingSharings;
-// JingleSessionManager* jingleSM;
-// IQRouter* iqRouter;
-// BoostUDPSocketFactory* udpSocketFactory;
-// TimerFactory* timerFactory;
EntityCapsProvider* capsProvider;
PresenceOracle* presenceOracle;
};