feat(ui/views/App/Calls/ConferenceManager): in progress

This commit is contained in:
Ronan Abhamon 2017-05-24 14:49:58 +02:00
parent 13e4822e2c
commit d5ccf5b724
7 changed files with 20 additions and 26 deletions

View file

@ -363,10 +363,6 @@ Server url not configured.</translation>
<source>conferenceTitle</source>
<translation>CONFERENCE</translation>
</message>
<message>
<source>pendingRequestLabel</source>
<translation>Please to wait, a request is pending.</translation>
</message>
</context>
<context>
<name>ConferenceManager</name>

View file

@ -363,10 +363,6 @@ Url du serveur non configurée.</translation>
<source>conferenceTitle</source>
<translation>CONFÉRENCE</translation>
</message>
<message>
<source>pendingRequestLabel</source>
<translation>Merci de patienter, une requête est en attente.</translation>
</message>
</context>
<context>
<name>ConferenceManager</name>

View file

@ -24,6 +24,7 @@
#include "../../Utils.hpp"
#include "../core/CoreManager.hpp"
#include "ConferenceHelperModel.hpp"
#include "ConferenceModel.hpp"
@ -57,6 +58,18 @@ QVariant ConferenceModel::data (const QModelIndex &index, int role) const {
// -----------------------------------------------------------------------------
void ConferenceModel::terminate () {
shared_ptr<linphone::Core> core = CoreManager::getInstance()->getCore();
core->terminateConference();
for (const auto &call : core->getCalls()) {
if (call->getParams()->getLocalConferenceMode())
call->terminate();
}
}
// -----------------------------------------------------------------------------
void ConferenceModel::startRecording () {
if (mRecording)
return;

View file

@ -43,6 +43,8 @@ public:
QHash<int, QByteArray> roleNames () const override;
QVariant data (const QModelIndex &index, int role = Qt::DisplayRole) const override;
Q_INVOKABLE void terminate ();
Q_INVOKABLE void startRecording ();
Q_INVOKABLE void stopRecording ();

View file

@ -12,12 +12,15 @@ var forceClose = false
function handleClosing (close) {
var callsList = Linphone.CallsListModel
window.detachVirtualWindow()
if (forceClose || callsList.getRunningCallsNumber() === 0) {
forceClose = false
callsList.terminateAllCalls()
return
}
window.detachVirtualWindow()
window.attachVirtualWindow(Utils.buildDialogUri('ConfirmDialog'), {
descriptionText: qsTr('acceptClosingDescription'),
}, function (status) {

View file

@ -1,5 +1,4 @@
import QtQuick 2.7
import QtQuick.Controls 2.1
import QtQuick.Layouts 1.3
import Common 1.0
@ -9,8 +8,6 @@ import Utils 1.0
import App.Styles 1.0
//import 'Conference.js' as Logic
// =============================================================================
Rectangle {
@ -192,19 +189,6 @@ Rectangle {
}
iconSize: CallStyle.actionArea.iconSize
ActionSwitch {
enabled: !conference.pausedByUser
icon: 'pause'
updating: conference.updating
onClicked: conference.pausedByUser = enabled
TooltipArea {
text: qsTr('pendingRequestLabel')
visible: parent.updating
}
}
ActionButton {
icon: 'hangup'

@ -1 +1 @@
Subproject commit ef9a19def1bb0ac28af4f1963a248959e46dee97
Subproject commit 87ca1adf5ef967bb3876ea0c060cb9135f36718d