From 3d0fe1a7327a7373b11395e5205f7f40da101c38 Mon Sep 17 00:00:00 2001 From: Gaelle Braud Date: Fri, 14 Jun 2024 12:16:44 +0200 Subject: [PATCH] leave/enter conference + fix call paused by remote --- Linphone/core/call/CallCore.cpp | 8 ++--- Linphone/core/call/CallCore.hpp | 9 ++--- .../participant/ParticipantDeviceCore.cpp | 30 ++++++++-------- .../participant/ParticipantDeviceCore.hpp | 3 +- Linphone/model/call/CallModel.cpp | 20 ++++++----- Linphone/model/conference/ConferenceModel.cpp | 3 -- Linphone/model/conference/ConferenceModel.hpp | 11 +++--- .../participant/ParticipantDeviceModel.hpp | 1 - Linphone/view/App/CallsWindow.qml | 21 ++++++----- Linphone/view/Item/Call/WaitingRoom.qml | 1 - Linphone/view/Item/Contact/Sticker.qml | 35 +++++++++++++++---- Linphone/view/Layout/Call/GridLayout.qml | 2 -- 12 files changed, 80 insertions(+), 64 deletions(-) diff --git a/Linphone/core/call/CallCore.cpp b/Linphone/core/call/CallCore.cpp index 2bf21af17..eba1fb375 100644 --- a/Linphone/core/call/CallCore.cpp +++ b/Linphone/core/call/CallCore.cpp @@ -441,10 +441,6 @@ void CallCore::setIsSecured(bool secured) { } } -bool CallCore::isConference() const { - return mIsConference; -} - ConferenceGui *CallCore::getConferenceGui() const { return mConference ? new ConferenceGui(mConference) : nullptr; } @@ -463,6 +459,10 @@ void CallCore::setConference(const QSharedPointer &conference) { } } +bool CallCore::isConference() const { + return mIsConference; +} + QString CallCore::getLocalSas() { return mLocalSas; } diff --git a/Linphone/core/call/CallCore.hpp b/Linphone/core/call/CallCore.hpp index 05a91c998..817d50170 100644 --- a/Linphone/core/call/CallCore.hpp +++ b/Linphone/core/call/CallCore.hpp @@ -46,7 +46,6 @@ class CallCore : public QObject, public AbstractObject { Q_PROPERTY(QString peerAddress READ getPeerAddress CONSTANT) Q_PROPERTY(QString localAddress READ getLocalAddress CONSTANT) Q_PROPERTY(bool isSecured READ isSecured NOTIFY securityUpdated) - Q_PROPERTY(bool isConference READ isConference NOTIFY conferenceChanged) Q_PROPERTY(LinphoneEnums::MediaEncryption encryption READ getEncryption NOTIFY securityUpdated) Q_PROPERTY(QString localSas READ getLocalSas WRITE setLocalSas MEMBER mLocalSas NOTIFY localSasChanged) Q_PROPERTY(QString remoteSas WRITE setRemoteSas MEMBER mRemoteSas NOTIFY remoteSasChanged) @@ -64,11 +63,12 @@ class CallCore : public QObject, public AbstractObject { Q_PROPERTY(float microVolume READ getMicrophoneVolume WRITE setMicrophoneVolume NOTIFY microphoneVolumeChanged) Q_PROPERTY(LinphoneEnums::CallState transferState READ getTransferState NOTIFY transferStateChanged) Q_PROPERTY(ConferenceGui *conference READ getConferenceGui NOTIFY conferenceChanged) + Q_PROPERTY(bool isConference READ isConference NOTIFY conferenceChanged) Q_PROPERTY(LinphoneEnums::ConferenceLayout conferenceVideoLayout READ getConferenceVideoLayout WRITE lSetConferenceVideoLayout NOTIFY conferenceVideoLayoutChanged) Q_PROPERTY(VideoSourceDescriptorGui *videoSourceDescriptor READ getVideoSourceDescriptorGui WRITE - lSetVideoSourceDescriptor NOTIFY videoSourceDescriptorChanged) + lSetVideoSourceDescriptor NOTIFY videoSourceDescriptorChanged) public: // Should be call from model Thread. Will be automatically in App thread after initialization @@ -107,11 +107,12 @@ public: bool isSecured() const; void setIsSecured(bool secured); - bool isConference() const; ConferenceGui *getConferenceGui() const; QSharedPointer getConferenceCore() const; void setConference(const QSharedPointer &conference); + bool isConference() const; + QString getLocalSas(); void setLocalSas(const QString &sas); QString getRemoteSas(); @@ -236,7 +237,6 @@ private: QString mPeerAddress; QString mLocalAddress; bool mIsSecured; - bool mIsConference = false; int mDuration = 0; bool mSpeakerMuted; bool mMicrophoneMuted; @@ -247,6 +247,7 @@ private: bool mRecording = false; bool mRemoteRecording = false; bool mRecordable = false; + bool mIsConference = false; QString mLocalSas; QString mRemoteSas; float mSpeakerVolumeGain; diff --git a/Linphone/core/participant/ParticipantDeviceCore.cpp b/Linphone/core/participant/ParticipantDeviceCore.cpp index e03f0724c..d104b72d1 100644 --- a/Linphone/core/participant/ParticipantDeviceCore.cpp +++ b/Linphone/core/participant/ParticipantDeviceCore.cpp @@ -60,6 +60,8 @@ ParticipantDeviceCore::ParticipantDeviceCore(const std::shared_ptr