diff --git a/coreapi/linphonecore.c b/coreapi/linphonecore.c index 5d0ea9b27..a1f294a94 100644 --- a/coreapi/linphonecore.c +++ b/coreapi/linphonecore.c @@ -3644,9 +3644,7 @@ void linphone_core_notify_incoming_call(LinphoneCore *lc, LinphoneCall *call){ linphone_ringtoneplayer_start(lc->factory, lc->ringtoneplayer, ringcard, lc->sound_conf.local_ring, 2000); }else{ /* else play a tone within the context of the current call */ -#if 0 - call->ringing_beep=TRUE; -#endif + L_GET_PRIVATE_FROM_C_OBJECT(call)->setRingingBeep(true); linphone_core_play_named_tone(lc,LinphoneToneCallWaiting); } } @@ -6309,7 +6307,7 @@ void linphone_core_start_dtmf_stream(LinphoneCore* lc) { } void linphone_core_stop_ringing(LinphoneCore* lc) { - //LinphoneCall *call=linphone_core_get_current_call(lc); + LinphoneCall *call=linphone_core_get_current_call(lc); if (linphone_ringtoneplayer_is_started(lc->ringtoneplayer)) { linphone_ringtoneplayer_stop(lc->ringtoneplayer); } @@ -6319,12 +6317,10 @@ void linphone_core_stop_ringing(LinphoneCore* lc) { lc->dmfs_playing_start_time=0; lc->ringstream_autorelease=TRUE; } -#if 0 - if (call && call->ringing_beep){ + if (call && L_GET_PRIVATE_FROM_C_OBJECT(call)->getRingingBeep()) { linphone_core_stop_dtmf(lc); - call->ringing_beep=FALSE; + L_GET_PRIVATE_FROM_C_OBJECT(call)->setRingingBeep(false); } -#endif } void linphone_core_stop_dtmf_stream(LinphoneCore* lc) { diff --git a/src/call/call-p.h b/src/call/call-p.h index a6c0d1b98..dc93e6e86 100644 --- a/src/call/call-p.h +++ b/src/call/call-p.h @@ -56,7 +56,9 @@ public: unsigned int getMediaStartCount () const; MediaStream *getMediaStream (LinphoneStreamType type) const; SalCallOp *getOp () const; + bool getRingingBeep () const { return ringingBeep; } void setAudioMuted (bool value); + void setRingingBeep (bool value) { ringingBeep = value; } void createPlayer () const;