Skip to content
Snippets Groups Projects
Commit 99a88d80 authored by Alexandre Lision's avatar Alexandre Lision Committed by Stepan Salenikovich
Browse files

CallState: adapt to daemon API change


callStateChanged and sipCallStateChanged have been merged

Refs #69086

Signed-off-by: default avatarStepan Salenikovich <stepan.salenikovich@savoirfairelinux.com>
parent 9a71d37b
No related branches found
No related tags found
No related merge requests found
......@@ -95,7 +95,7 @@ public:
CallModel* q_ptr;
private Q_SLOTS:
void slotCallStateChanged ( const QString& callID , const QString &state );
void slotCallStateChanged ( const QString& callID , const QString &state, int code);
void slotIncomingCall ( const QString& accountID , const QString & callID );
void slotIncomingConference ( const QString& confID );
void slotChangingConference ( const QString& confID , const QString &state );
......@@ -156,7 +156,7 @@ void CallModelPrivate::init()
//SLOTS
/* SENDER SIGNAL RECEIVER SLOT */
/**/connect(&callManager, SIGNAL(callStateChanged(QString,QString)) , this , SLOT(slotCallStateChanged(QString,QString)) );
/**/connect(&callManager, SIGNAL(callStateChanged(QString,QString,int)) , this , SLOT(slotCallStateChanged(QString,QString,int)));
/**/connect(&callManager, SIGNAL(incomingCall(QString,QString,QString)) , this , SLOT(slotIncomingCall(QString,QString)) );
/**/connect(&callManager, SIGNAL(conferenceCreated(QString)) , this , SLOT(slotIncomingConference(QString)) );
/**/connect(&callManager, SIGNAL(conferenceChanged(QString,QString)) , this , SLOT(slotChangingConference(QString,QString)) );
......@@ -1012,7 +1012,7 @@ bool CallModel::dropMimeData(const QMimeData* mimedata, Qt::DropAction action, i
****************************************************************************/
///When a call state change
void CallModelPrivate::slotCallStateChanged(const QString& callID, const QString& stateName)
void CallModelPrivate::slotCallStateChanged(const QString& callID, const QString& stateName, int code)
{
//This code is part of the CallModel interface too
qDebug() << "Call State Changed for call " << callID << " . New state : " << stateName;
......
......@@ -50,9 +50,9 @@ public:
callHandlers = {
exportable_callback<CallSignal::StateChange>(
[this] (const std::string &callID, const std::string &state) {
QTimer::singleShot(0, [this,callID, state] {
emit this->callStateChanged(QString(callID.c_str()), QString(state.c_str()));
[this] (const std::string &callID, const std::string &state, int code) {
QTimer::singleShot(0, [this,callID, state, code] {
emit this->callStateChanged(QString(callID.c_str()), QString(state.c_str()), code);
});
}),
exportable_callback<CallSignal::TransferFailed>(
......@@ -128,12 +128,6 @@ public:
emit this->newCallCreated(QString(accountID.c_str()), QString(callID.c_str()), QString(to.c_str()));
});
}),
exportable_callback<CallSignal::SipCallStateChanged>(
[this] (const std::string &callID, const std::string &state, int code) {
QTimer::singleShot(0, [this,callID, state, code] {
emit this->sipCallStateChanged(QString(callID.c_str()), QString(state.c_str()), code);
});
}),
exportable_callback<CallSignal::RecordingStateChanged>(
[this] (const std::string &callID, bool recordingState) {
QTimer::singleShot(0, [this,callID, recordingState] {
......@@ -420,7 +414,7 @@ public Q_SLOTS: // METHODS
}
Q_SIGNALS: // SIGNALS
void callStateChanged(const QString &callID, const QString &state);
void callStateChanged(const QString &callID, const QString &state, int code);
void transferFailed();
void transferSucceeded();
void recordPlaybackStopped(const QString &filepath);
......@@ -433,7 +427,6 @@ Q_SIGNALS: // SIGNALS
void updatePlaybackScale(const QString &filepath, int position, int size);
void conferenceRemoved(const QString &confID);
void newCallCreated(const QString &accountID, const QString &callID, const QString &to);
void sipCallStateChanged(const QString &callID, const QString &state, int code);
void recordingStateChanged(const QString &callID, bool recordingState);
void secureSdesOn(const QString &callID);
void secureSdesOff(const QString &callID);
......
......@@ -505,6 +505,11 @@
</ul>
</tp:docstring>
</arg>
<arg type="i" name="code" >
<tp:docstring>
The SIP or IAX2 message code
</tp:docstring>
</arg>
</signal>
<signal name="conferenceChanged" tp:name-for-bindings="conferenceChanged">
......@@ -633,25 +638,6 @@
<arg type="s" name="filepath" direction="in"/>
</method>
<signal name="sipCallStateChanged" tp:name-for-bindings="sipCallStateChanged">
<tp:docstring>
<p>Call state changed, Ring received a notification
from registrar concerning this call.</p>
</tp:docstring>
<arg type="s" name="callID" />
<tp:docstring>
The call ID
</tp:docstring>
<arg type="s" name="state" />
<tp:docstring>
Description string
</tp:docstring>
<arg type="i" name="code" />
<tp:docstring>
The SIP or IAX2 message code
</tp:docstring>
</signal>
<signal name="voiceMailNotify" tp:name-for-bindings="voiceMailNotify">
<tp:docstring>
Notify the clients of the voicemail number for a specific account, if applicable.
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment