diff --git a/linphone-app/src/components/conference/ConferenceAddModel.cpp b/linphone-app/src/components/conference/ConferenceAddModel.cpp index 65889b886..eb1e04a73 100644 --- a/linphone-app/src/components/conference/ConferenceAddModel.cpp +++ b/linphone-app/src/components/conference/ConferenceAddModel.cpp @@ -147,10 +147,11 @@ bool ConferenceHelperModel::ConferenceAddModel::removeFromConference (const QStr void ConferenceHelperModel::ConferenceAddModel::update () { shared_ptr conference = mConferenceHelperModel->mCore->getConference(); - bool enablingVideo = true;// Video is not yet fully supported by the application in conference + bool enablingVideo = false;// Video is not yet fully supported by the application in conference if(!conference){ auto parameters = mConferenceHelperModel->mCore->createConferenceParams(conference); parameters->enableVideo(enablingVideo); + parameters->setConferenceFactoryAddress(nullptr);// Do a local conference conference = mConferenceHelperModel->mCore->createConferenceWithParams(parameters); } auto currentCalls = CoreManager::getInstance()->getCore()->getCalls(); diff --git a/linphone-app/src/components/conference/ConferenceModel.cpp b/linphone-app/src/components/conference/ConferenceModel.cpp index 03144b2ac..5c2bced0d 100644 --- a/linphone-app/src/components/conference/ConferenceModel.cpp +++ b/linphone-app/src/components/conference/ConferenceModel.cpp @@ -66,6 +66,7 @@ ConferenceModel::ConferenceModel (std::shared_ptr conferen connect(this, &ConferenceModel::participantDeviceAdded, this, &ConferenceModel::participantDeviceCountChanged); connect(this, &ConferenceModel::participantDeviceRemoved, this, &ConferenceModel::participantDeviceCountChanged); connect(mParticipantListModel.get(), &ParticipantListModel::participantsChanged, this, &ConferenceModel::participantDeviceCountChanged); + onConferenceStateChanged(mConference->getState());// Is it already Created like for local conference? } ConferenceModel::~ConferenceModel(){ diff --git a/linphone-app/src/components/participant/ParticipantDeviceModel.cpp b/linphone-app/src/components/participant/ParticipantDeviceModel.cpp index cb50084dc..76fc2bcb0 100644 --- a/linphone-app/src/components/participant/ParticipantDeviceModel.cpp +++ b/linphone-app/src/components/participant/ParticipantDeviceModel.cpp @@ -145,8 +145,8 @@ void ParticipantDeviceModel::updateVideoEnabled(){ ( mParticipantDevice->getStreamCapability(linphone::StreamType::Video) == linphone::MediaDirection::SendRecv || mParticipantDevice->getStreamCapability(linphone::StreamType::Video) == linphone::MediaDirection::SendOnly ) - || isMe()); - if( mIsVideoEnabled != enabled && mCall && mCall->getCall()->getState() == linphone::Call::State::StreamsRunning) { + || isMe()) && !mIsPaused; + if( mIsVideoEnabled != enabled && mCall && mCall->getCall()->getState() == linphone::Call::State::StreamsRunning) { qWarning() << "VideoEnabled: " << enabled << ", old=" << mIsVideoEnabled << (mParticipantDevice ? mParticipantDevice->getAddress()->asString().c_str() : "") << ", me=" << isMe() << ", CallState=" << (mCall ? (int)mCall->getCall()->getState() : -1); mIsVideoEnabled = enabled; emit videoEnabledChanged(); diff --git a/linphone-app/ui/modules/Linphone/Sticker/DecorationSticker.qml b/linphone-app/ui/modules/Linphone/Sticker/DecorationSticker.qml index f89a44b00..4e7410d7c 100644 --- a/linphone-app/ui/modules/Linphone/Sticker/DecorationSticker.qml +++ b/linphone-app/ui/modules/Linphone/Sticker/DecorationSticker.qml @@ -140,7 +140,14 @@ Item{ BusyIndicator{// Joining spinner Layout.preferredHeight: 20 Layout.preferredWidth: 20 - running: mainItem._currentDevice && (mainItem._currentDevice.state == LinphoneEnums.ParticipantDeviceStateJoining || mainItem._currentDevice.state == LinphoneEnums.ParticipantDeviceStateScheduledForJoining || mainItem._currentDevice.state == LinphoneEnums.ParticipantDeviceStateAlerting) + property bool delayed : false + visible: delayed && mainItem._currentDevice && (mainItem._currentDevice.state == LinphoneEnums.ParticipantDeviceStateJoining || mainItem._currentDevice.state == LinphoneEnums.ParticipantDeviceStateScheduledForJoining || mainItem._currentDevice.state == LinphoneEnums.ParticipantDeviceStateAlerting) + Timer{// Delay starting spinner (Qt bug) + id: indicatorDelay + interval: 100 + onTriggered: parent.delayed = true + } + Component.onCompleted: indicatorDelay.start() } } } diff --git a/linphone-app/ui/views/App/Main/Conversation.qml b/linphone-app/ui/views/App/Main/Conversation.qml index 9afb70e1a..65036c687 100644 --- a/linphone-app/ui/views/App/Main/Conversation.qml +++ b/linphone-app/ui/views/App/Main/Conversation.qml @@ -204,7 +204,7 @@ ColumnLayout { } */ onTitleClicked: { - if(!conversation.isReadOnly) { + if(!conversation.chatRoomModel.isReadOnly) { usernameEdit.visible = !usernameEdit.visible usernameEdit.forceActiveFocus() } @@ -224,7 +224,7 @@ ColumnLayout { iconSize:30 MouseArea{ anchors.fill:parent - visible: !conversation.isReadOnly + visible: !conversation.chatRoomModel.isReadOnly onClicked : { window.detachVirtualWindow() window.attachVirtualWindow(Qt.resolvedUrl('Dialogs/InfoEncryption.qml') @@ -329,17 +329,21 @@ ColumnLayout { backgroundRadius: 1000 colorSet: ConversationStyle.bar.actions.groupChat - visible: SettingsModel.videoConferenceEnabled && SettingsModel.outgoingCallsEnabled && conversation.haveMoreThanOneParticipants && conversation.haveLessThanMinParticipantsForCall && !conversation.isReadOnly + visible: !conversation.chatRoomModel.isReadOnly && conversation.haveMoreThanOneParticipants && SettingsModel.outgoingCallsEnabled && (SettingsModel.videoConferenceEnabled || conversation.haveLessThanMinParticipantsForCall) //onClicked: CallsListModel. Logic.openConferenceManager({chatRoomModel:conversation.chatRoomModel, autoCall:true}) onClicked:{ - groupCallButton.toggled = true - conferenceInfoModel.isScheduled = false - conferenceInfoModel.subject = chatRoomModel.subject + if( SettingsModel.videoConferenceEnabled ){ + groupCallButton.toggled = true + conferenceInfoModel.isScheduled = false + conferenceInfoModel.subject = chatRoomModel.subject - conferenceInfoModel.setParticipants(conversation.chatRoomModel.participants) - conferenceInfoModel.inviteMode = 0; - conferenceInfoModel.createConference(false)// TODO activate it when secure video conference is implemented + conferenceInfoModel.setParticipants(conversation.chatRoomModel.participants) + conferenceInfoModel.inviteMode = 0; + conferenceInfoModel.createConference(false)// TODO activate it when secure video conference is implemented + }else{ + Logic.openConferenceManager({chatRoomModel:conversation.chatRoomModel, autoCall:true}) + } } //: "Call all chat room's participants" : tooltip on a button for calling all participant in the current chat room tooltipText: qsTr("groupChatCallButton")