Skip to content
Snippets Groups Projects
Commit d346a1c7 authored by Emmanuel Milou's avatar Emmanuel Milou
Browse files

Correct the dtmf sound when dialing with ALSA plugin plughw

parent 54c879bb
No related branches found
No related tags found
No related merge requests found
...@@ -357,7 +357,10 @@ sflphone_incoming_call (call_t * c) ...@@ -357,7 +357,10 @@ sflphone_incoming_call (call_t * c)
void process_dialing(call_t * c, guint keyval, gchar * key) void process_dialing(call_t * c, guint keyval, gchar * key)
{ {
// We stop the tone // We stop the tone
if(strlen(c->to) == 0){
dbus_start_tone( FALSE , 0 ); dbus_start_tone( FALSE , 0 );
dbus_play_dtmf( key );
}
switch (keyval) switch (keyval)
{ {
case 65293: /* ENTER */ case 65293: /* ENTER */
......
...@@ -68,13 +68,9 @@ AudioLayer::openDevice (int indexIn, int indexOut, int sampleRate, int frameSize ...@@ -68,13 +68,9 @@ AudioLayer::openDevice (int indexIn, int indexOut, int sampleRate, int frameSize
if(deviceClosed == false) if(deviceClosed == false)
{ {
if( stream == SFL_PCM_CAPTURE ) if( stream == SFL_PCM_CAPTURE )
{
closeCaptureStream(); closeCaptureStream();
}
else if( stream == SFL_PCM_PLAYBACK) else if( stream == SFL_PCM_PLAYBACK)
{
closePlaybackStream(); closePlaybackStream();
}
else else
{ {
closeCaptureStream(); closeCaptureStream();
...@@ -118,6 +114,7 @@ AudioLayer::startStream(void) ...@@ -118,6 +114,7 @@ AudioLayer::startStream(void)
AudioLayer::stopStream(void) AudioLayer::stopStream(void)
{ {
//ost::MutexLock lock( _mutex ); //ost::MutexLock lock( _mutex );
_debugAlsa(" Stop Stream\n ");
_talk = false; _talk = false;
snd_pcm_drop( _CaptureHandle ); snd_pcm_drop( _CaptureHandle );
snd_pcm_prepare( _CaptureHandle ); snd_pcm_prepare( _CaptureHandle );
...@@ -600,7 +597,6 @@ AudioLayer::closePlaybackStream( void) ...@@ -600,7 +597,6 @@ AudioLayer::closePlaybackStream( void)
} }
} }
bool bool
AudioLayer::soundCardIndexExist( int card , int stream ) AudioLayer::soundCardIndexExist( int card , int stream )
{ {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment