diff --git a/src/voip/CallManager.cpp b/src/voip/CallManager.cpp
index 54d86620..617f687c 100644
--- a/src/voip/CallManager.cpp
+++ b/src/voip/CallManager.cpp
@@ -36,12 +36,12 @@ extern "C"
}
#endif
-Q_DECLARE_METATYPE(std::vector<mtx::events::msg::CallCandidates::Candidate>)
-Q_DECLARE_METATYPE(mtx::events::msg::CallCandidates::Candidate)
+Q_DECLARE_METATYPE(std::vector<mtx::events::voip::CallCandidates::Candidate>)
+Q_DECLARE_METATYPE(mtx::events::voip::CallCandidates::Candidate)
Q_DECLARE_METATYPE(mtx::responses::TurnServer)
using namespace mtx::events;
-using namespace mtx::events::msg;
+using namespace mtx::events::voip;
using webrtc::CallType;
@@ -55,8 +55,8 @@ CallManager::CallManager(QObject *parent)
, session_(WebRTCSession::instance())
, turnServerTimer_(this)
{
- qRegisterMetaType<std::vector<mtx::events::msg::CallCandidates::Candidate>>();
- qRegisterMetaType<mtx::events::msg::CallCandidates::Candidate>();
+ qRegisterMetaType<std::vector<mtx::events::voip::CallCandidates::Candidate>>();
+ qRegisterMetaType<mtx::events::voip::CallCandidates::Candidate>();
qRegisterMetaType<mtx::responses::TurnServer>();
connect(
diff --git a/src/voip/CallManager.h b/src/voip/CallManager.h
index a505e995..c17182f0 100644
--- a/src/voip/CallManager.h
+++ b/src/voip/CallManager.h
@@ -67,15 +67,15 @@ public slots:
void toggleMicMute();
void toggleLocalPiP() { session_.toggleLocalPiP(); }
void acceptInvite();
- void hangUp(mtx::events::msg::CallHangUp::Reason = mtx::events::msg::CallHangUp::Reason::User);
+ void hangUp(mtx::events::voip::CallHangUp::Reason = mtx::events::voip::CallHangUp::Reason::User);
QStringList windowList();
void previewWindow(unsigned int windowIndex) const;
signals:
- void newMessage(const QString &roomid, const mtx::events::msg::CallInvite &);
- void newMessage(const QString &roomid, const mtx::events::msg::CallCandidates &);
- void newMessage(const QString &roomid, const mtx::events::msg::CallAnswer &);
- void newMessage(const QString &roomid, const mtx::events::msg::CallHangUp &);
+ void newMessage(const QString &roomid, const mtx::events::voip::CallInvite &);
+ void newMessage(const QString &roomid, const mtx::events::voip::CallCandidates &);
+ void newMessage(const QString &roomid, const mtx::events::voip::CallAnswer &);
+ void newMessage(const QString &roomid, const mtx::events::voip::CallHangUp &);
void newInviteState();
void newCallState();
void micMuteChanged();
@@ -96,7 +96,7 @@ private:
webrtc::CallType callType_ = webrtc::CallType::VOICE;
bool haveCallInvite_ = false;
std::string inviteSDP_;
- std::vector<mtx::events::msg::CallCandidates::Candidate> remoteICECandidates_;
+ std::vector<mtx::events::voip::CallCandidates::Candidate> remoteICECandidates_;
std::vector<std::string> turnURIs_;
QTimer turnServerTimer_;
QMediaPlayer player_;
@@ -104,11 +104,11 @@ private:
template<typename T>
bool handleEvent(const mtx::events::collections::TimelineEvents &event);
- void handleEvent(const mtx::events::RoomEvent<mtx::events::msg::CallInvite> &);
- void handleEvent(const mtx::events::RoomEvent<mtx::events::msg::CallCandidates> &);
- void handleEvent(const mtx::events::RoomEvent<mtx::events::msg::CallAnswer> &);
- void handleEvent(const mtx::events::RoomEvent<mtx::events::msg::CallHangUp> &);
- void answerInvite(const mtx::events::msg::CallInvite &, bool isVideo);
+ void handleEvent(const mtx::events::RoomEvent<mtx::events::voip::CallInvite> &);
+ void handleEvent(const mtx::events::RoomEvent<mtx::events::voip::CallCandidates> &);
+ void handleEvent(const mtx::events::RoomEvent<mtx::events::voip::CallAnswer> &);
+ void handleEvent(const mtx::events::RoomEvent<mtx::events::voip::CallHangUp> &);
+ void answerInvite(const mtx::events::voip::CallInvite &, bool isVideo);
void generateCallID();
QStringList devices(bool isVideo) const;
void clear();
diff --git a/src/voip/WebRTCSession.cpp b/src/voip/WebRTCSession.cpp
index 31174500..a99ff5b8 100644
--- a/src/voip/WebRTCSession.cpp
+++ b/src/voip/WebRTCSession.cpp
@@ -105,7 +105,7 @@ WebRTCSession::init(std::string *errorMessage)
namespace {
std::string localsdp_;
-std::vector<mtx::events::msg::CallCandidates::Candidate> localcandidates_;
+std::vector<mtx::events::voip::CallCandidates::Candidate> localcandidates_;
bool haveAudioStream_ = false;
bool haveVideoStream_ = false;
GstPad *localPiPSinkPad_ = nullptr;
@@ -726,7 +726,7 @@ WebRTCSession::acceptAnswer(const std::string &sdp)
void
WebRTCSession::acceptICECandidates(
- const std::vector<mtx::events::msg::CallCandidates::Candidate> &candidates)
+ const std::vector<mtx::events::voip::CallCandidates::Candidate> &candidates)
{
if (state_ >= State::INITIATED) {
for (const auto &c : candidates) {
@@ -1151,7 +1151,7 @@ WebRTCSession::acceptAnswer(const std::string &)
}
void
-WebRTCSession::acceptICECandidates(const std::vector<mtx::events::msg::CallCandidates::Candidate> &)
+WebRTCSession::acceptICECandidates(const std::vector<mtx::events::voip::CallCandidates::Candidate> &)
{}
bool
diff --git a/src/voip/WebRTCSession.h b/src/voip/WebRTCSession.h
index 04383679..ac1845c7 100644
--- a/src/voip/WebRTCSession.h
+++ b/src/voip/WebRTCSession.h
@@ -64,7 +64,7 @@ public:
bool createOffer(webrtc::CallType, uint32_t shareWindowId);
bool acceptOffer(const std::string &sdp);
bool acceptAnswer(const std::string &sdp);
- void acceptICECandidates(const std::vector<mtx::events::msg::CallCandidates::Candidate> &);
+ void acceptICECandidates(const std::vector<mtx::events::voip::CallCandidates::Candidate> &);
bool isMicMuted() const;
bool toggleMicMute();
@@ -78,10 +78,10 @@ public:
signals:
void offerCreated(const std::string &sdp,
- const std::vector<mtx::events::msg::CallCandidates::Candidate> &);
+ const std::vector<mtx::events::voip::CallCandidates::Candidate> &);
void answerCreated(const std::string &sdp,
- const std::vector<mtx::events::msg::CallCandidates::Candidate> &);
- void newICECandidate(const mtx::events::msg::CallCandidates::Candidate &);
+ const std::vector<mtx::events::voip::CallCandidates::Candidate> &);
+ void newICECandidate(const mtx::events::voip::CallCandidates::Candidate &);
void stateChanged(webrtc::State);
private slots:
|