...
 
Commits (1)
...@@ -3999,6 +3999,10 @@ LinphoneStatus linphone_core_terminate_call(LinphoneCore *lc, LinphoneCall *call ...@@ -3999,6 +3999,10 @@ LinphoneStatus linphone_core_terminate_call(LinphoneCore *lc, LinphoneCall *call
return linphone_call_terminate(call); return linphone_call_terminate(call);
} }
void linphone_core_reset_sound_card(LinphoneCore *lc) {
return L_GET_CPP_PTR_FROM_C_OBJECT(lc)->resetSoundCard();
}
LinphoneStatus linphone_core_terminate_all_calls(LinphoneCore *lc) { LinphoneStatus linphone_core_terminate_all_calls(LinphoneCore *lc) {
return L_GET_CPP_PTR_FROM_C_OBJECT(lc)->terminateAllCalls(); return L_GET_CPP_PTR_FROM_C_OBJECT(lc)->terminateAllCalls();
} }
......
...@@ -1375,6 +1375,11 @@ LINPHONE_PUBLIC LINPHONE_DEPRECATED LinphoneStatus linphone_core_decline_call(Li ...@@ -1375,6 +1375,11 @@ LINPHONE_PUBLIC LINPHONE_DEPRECATED LinphoneStatus linphone_core_decline_call(Li
**/ **/
LINPHONE_PUBLIC LinphoneStatus linphone_core_terminate_all_calls(LinphoneCore *lc); LINPHONE_PUBLIC LinphoneStatus linphone_core_terminate_all_calls(LinphoneCore *lc);
/**
* reset the sound card.
* @param[in] lc #LinphoneCore object
**/
LINPHONE_PUBLIC void linphone_core_reset_sound_card(LinphoneCore *lc);
/** /**
* @brief Pauses the call. If a music file has been setup using linphone_core_set_play_file(), * @brief Pauses the call. If a music file has been setup using linphone_core_set_play_file(),
* this file will be played to the remote user. * this file will be played to the remote user.
......
...@@ -306,11 +306,16 @@ void Core::soundcardHintCheck () { ...@@ -306,11 +306,16 @@ void Core::soundcardHintCheck () {
if ((!d->hasCalls() || noNeedForSound) if ((!d->hasCalls() || noNeedForSound)
&& (!L_GET_C_BACK_PTR(getSharedFromThis())->use_files && (!useRtpIo || (useRtpIo && useRtpIoEnableLocalOutput)))) { && (!L_GET_C_BACK_PTR(getSharedFromThis())->use_files && (!useRtpIo || (useRtpIo && useRtpIoEnableLocalOutput)))) {
lInfo() << "Notifying soundcard that we don't need it anymore for calls"; resetSoundCard();
d->notifySoundcardUsage(false);
} }
} }
void Core::resetSoundCard () {
L_D();
lInfo() << "Notifying soundcard that we don't need it anymore for calls";
d->notifySoundcardUsage(false);
}
LinphoneStatus Core::terminateAllCalls () { LinphoneStatus Core::terminateAllCalls () {
L_D(); L_D();
while (!d->calls.empty()) { while (!d->calls.empty()) {
......
...@@ -100,6 +100,7 @@ public: ...@@ -100,6 +100,7 @@ public:
LinphoneStatus pauseAllCalls (); LinphoneStatus pauseAllCalls ();
void soundcardHintCheck (); void soundcardHintCheck ();
LinphoneStatus terminateAllCalls (); LinphoneStatus terminateAllCalls ();
void resetSoundCard ();
// --------------------------------------------------------------------------- // ---------------------------------------------------------------------------
// ChatRoom. // ChatRoom.
......