@ -150,7 +150,7 @@ void AlsaSoundDevice::saveState (KConfig *c) const
int i = 0 ;
int i = 0 ;
for ( TQMapConstIterator < TQString , AlsaConfigMixerSetting > it = m_CaptureMixerSettings . begin ( ) ; it ! = m_CaptureMixerSettings . end ( ) ; + + it , + + i ) {
for ( TQMapConstIterator < TQString , AlsaConfigMixerSetting > it = m_CaptureMixerSettings . begin ( ) ; it ! = m_CaptureMixerSettings . end ( ) ; + + it , + + i ) {
TQString prefix = TQString ( " mixer-setting-%1- " ) . arg( i ) ;
TQString prefix = TQString ( " mixer-setting-%1- " ) . tq arg( i ) ;
( * it ) . saveState ( c , prefix ) ;
( * it ) . saveState ( c , prefix ) ;
}
}
@ -179,7 +179,7 @@ void AlsaSoundDevice::restoreState (KConfig *c)
int n = c - > readNumEntry ( " mixer-settings " , 0 ) ;
int n = c - > readNumEntry ( " mixer-settings " , 0 ) ;
for ( int i = 0 ; i < n ; + + i ) {
for ( int i = 0 ; i < n ; + + i ) {
TQString prefix = TQString ( " mixer-setting-%1- " ) . arg( i ) ;
TQString prefix = TQString ( " mixer-setting-%1- " ) . tq arg( i ) ;
AlsaConfigMixerSetting s ( c , prefix ) ;
AlsaConfigMixerSetting s ( c , prefix ) ;
m_CaptureMixerSettings . insert ( s . getIDString ( ) , s ) ;
m_CaptureMixerSettings . insert ( s . getIDString ( ) , s ) ;
}
}
@ -418,9 +418,9 @@ bool AlsaSoundDevice::stopCapture(SoundStreamID id)
slotPollCapture ( ) ;
slotPollCapture ( ) ;
// if (m_captureThread->error()) {
// if (m_captureThread->error()) {
// logError(i18n("ALSA Plugin, device plughw:%1,%2: %3"). arg(m_CaptureCard)
// logError(i18n("ALSA Plugin, device plughw:%1,%2: %3"). tq arg(m_CaptureCard)
// . arg(m_CaptureDevice)
// . tq arg(m_CaptureDevice)
// . arg(i18n("unknown error")));
// . tq arg(i18n("unknown error")));
// }
// }
//
//
// delete m_captureThread;
// delete m_captureThread;
@ -526,7 +526,7 @@ bool AlsaSoundDevice::noticeSoundStreamData(SoundStreamID id,
/* if (n < size) {
/* if (n < size) {
m_PlaybackSkipCount + = size - n ;
m_PlaybackSkipCount + = size - n ;
} else if ( m_PlaybackSkipCount > 0 ) {
} else if ( m_PlaybackSkipCount > 0 ) {
logWarning ( i18n ( " plughw:%1,%2: Playback buffer overflow. Skipped %3 bytes " ) . arg( m_PlaybackCard ) . arg( m_PlaybackDevice ) . arg( TQString : : number ( m_PlaybackSkipCount ) ) ) ;
logWarning ( i18n ( " plughw:%1,%2: Playback buffer overflow. Skipped %3 bytes " ) . tq arg( m_PlaybackCard ) . tq arg( m_PlaybackDevice ) . tq arg( TQString : : number ( m_PlaybackSkipCount ) ) ) ;
m_PlaybackSkipCount = 0 ;
m_PlaybackSkipCount = 0 ;
}
}
return m_PlaybackSkipCount = = 0 ; */
return m_PlaybackSkipCount = = 0 ; */
@ -550,12 +550,12 @@ void AlsaSoundDevice::slotPollPlayback()
if ( framesWritten > 0 ) {
if ( framesWritten > 0 ) {
m_PlaybackBuffer . removeData ( bytesWritten ) ;
m_PlaybackBuffer . removeData ( bytesWritten ) ;
} else if ( framesWritten = = 0 ) {
} else if ( framesWritten = = 0 ) {
logError ( i18n ( " ALSA Plugin: cannot write data for device plughw:%1,%2 " ) . arg( m_PlaybackCard ) . arg( m_PlaybackDevice ) ) ;
logError ( i18n ( " ALSA Plugin: cannot write data for device plughw:%1,%2 " ) . tq arg( m_PlaybackCard ) . tq arg( m_PlaybackDevice ) ) ;
} else if ( framesWritten = = - EAGAIN ) {
} else if ( framesWritten = = - EAGAIN ) {
// do nothing
// do nothing
} else {
} else {
snd_pcm_prepare ( m_hPlayback ) ;
snd_pcm_prepare ( m_hPlayback ) ;
logWarning ( i18n ( " ALSA Plugin: buffer underrun for device plughw:%1,%2 " ) . arg( m_PlaybackCard ) . arg( m_PlaybackDevice ) ) ;
logWarning ( i18n ( " ALSA Plugin: buffer underrun for device plughw:%1,%2 " ) . tq arg( m_PlaybackCard ) . tq arg( m_PlaybackDevice ) ) ;
}
}
}
}
@ -577,7 +577,7 @@ void AlsaSoundDevice::slotPollCapture()
if ( m_CaptureStreamID . isValid ( ) & & m_hCapture ) {
if ( m_CaptureStreamID . isValid ( ) & & m_hCapture ) {
// while (m_captureThread && m_captureThread->getAvailableReadBuffers()) {
// while (m_captureThread && m_captureThread->getAvailableReadBuffers()) {
// TQString dev = TQString("alsa://plughw:%1,%2"). arg(m_CaptureCard).arg(m_CaptureDevice);
// TQString dev = TQString("alsa://plughw:%1,%2"). tq arg(m_CaptureCard).tq arg(m_CaptureDevice);
// size_t size = 0;
// size_t size = 0;
// char *buffer = m_captureThread->getReadBuffer(size);
// char *buffer = m_captureThread->getReadBuffer(size);
// time_t cur_time = time(NULL);
// time_t cur_time = time(NULL);
@ -608,22 +608,22 @@ void AlsaSoundDevice::slotPollCapture()
m_CaptureBuffer . removeFreeSpace ( bytesRead ) ;
m_CaptureBuffer . removeFreeSpace ( bytesRead ) ;
} else if ( framesRead = = 0 ) {
} else if ( framesRead = = 0 ) {
snd_pcm_prepare ( m_hCapture ) ;
snd_pcm_prepare ( m_hCapture ) ;
logError ( i18n ( " ALSA Plugin: cannot read data from device plughw:%1,%2 " ) . arg( m_CaptureCard ) . arg( m_CaptureDevice ) ) ;
logError ( i18n ( " ALSA Plugin: cannot read data from device plughw:%1,%2 " ) . tq arg( m_CaptureCard ) . tq arg( m_CaptureDevice ) ) ;
} else if ( framesRead = = - EAGAIN ) {
} else if ( framesRead = = - EAGAIN ) {
// do nothing
// do nothing
} else {
} else {
snd_pcm_prepare ( m_hCapture ) ;
snd_pcm_prepare ( m_hCapture ) ;
logWarning ( i18n ( " ALSA Plugin: buffer overrun for device plughw:%1,%2 (buffersize=%3, buffer=%4) " ) . arg( m_CaptureCard ) . arg( m_CaptureDevice ) . arg( bufferSize ) . arg( ( long long unsigned ) buffer ) ) ;
logWarning ( i18n ( " ALSA Plugin: buffer overrun for device plughw:%1,%2 (buffersize=%3, buffer=%4) " ) . tq arg( m_CaptureCard ) . tq arg( m_CaptureDevice ) . tq arg( bufferSize ) . tq arg( ( long long unsigned ) buffer ) ) ;
}
}
TQString dev = TQString ( " alsa://plughw:%1,%2 " ) . arg( m_CaptureCard ) . arg( m_CaptureDevice ) ;
TQString dev = TQString ( " alsa://plughw:%1,%2 " ) . tq arg( m_CaptureCard ) . tq arg( m_CaptureDevice ) ;
while ( m_CaptureBuffer . getFillSize ( ) > m_CaptureBuffer . getSize ( ) / 3 ) {
while ( m_CaptureBuffer . getFillSize ( ) > m_CaptureBuffer . getSize ( ) / 3 ) {
size_t size = 0 ;
size_t size = 0 ;
buffer = m_CaptureBuffer . getData ( size ) ;
buffer = m_CaptureBuffer . getData ( size ) ;
time_t cur_time = time ( NULL ) ;
time_t cur_time = time ( NULL ) ;
size_t consumed_size = SIZE_T_DONT_CARE ;
size_t consumed_size = SIZE_T_DONT_CARE ;
notifySoundStreamData ( m_CaptureStreamID , m_CaptureFormat , buffer , size , consumed_size , SoundMetaData ( m_CapturePos , cur_time - m_CaptureStartTime , cur_time , i18n ( " internal stream, not stored (%1) " ) . arg( dev ) ) ) ;
notifySoundStreamData ( m_CaptureStreamID , m_CaptureFormat , buffer , size , consumed_size , SoundMetaData ( m_CapturePos , cur_time - m_CaptureStartTime , cur_time , i18n ( " internal stream, not stored (%1) " ) . tq arg( dev ) ) ) ;
if ( consumed_size = = SIZE_T_DONT_CARE )
if ( consumed_size = = SIZE_T_DONT_CARE )
consumed_size = size ;
consumed_size = size ;
@ -664,7 +664,7 @@ bool AlsaSoundDevice::openPlaybackDevice(const SoundFormat &format, bool reopen)
m_PlaybackFormat = format ;
m_PlaybackFormat = format ;
TQString dev = TQString ( " plughw:%1,%2 " ) . arg( m_PlaybackCard ) . arg( m_PlaybackDevice ) ;
TQString dev = TQString ( " plughw:%1,%2 " ) . tq arg( m_PlaybackCard ) . tq arg( m_PlaybackDevice ) ;
bool error = ! openAlsaDevice ( m_hPlayback , m_PlaybackFormat , dev . ascii ( ) , SND_PCM_STREAM_PLAYBACK , SND_PCM_NONBLOCK , m_PlaybackLatency ) ;
bool error = ! openAlsaDevice ( m_hPlayback , m_PlaybackFormat , dev . ascii ( ) , SND_PCM_STREAM_PLAYBACK , SND_PCM_NONBLOCK , m_PlaybackLatency ) ;
if ( ! error ) {
if ( ! error ) {
@ -704,7 +704,7 @@ bool AlsaSoundDevice::openCaptureDevice(const SoundFormat &format, bool reopen)
m_CaptureFormat = format ;
m_CaptureFormat = format ;
TQString dev = TQString ( " plughw:%1,%2 " ) . arg( m_CaptureCard ) . arg( m_CaptureDevice ) ;
TQString dev = TQString ( " plughw:%1,%2 " ) . tq arg( m_CaptureCard ) . tq arg( m_CaptureDevice ) ;
// bool error = !openAlsaDevice(m_hCapture, m_CaptureFormat, dev.ascii(), SND_PCM_STREAM_CAPTURE, /*flags = block*/0, m_CaptureLatency);
// bool error = !openAlsaDevice(m_hCapture, m_CaptureFormat, dev.ascii(), SND_PCM_STREAM_CAPTURE, /*flags = block*/0, m_CaptureLatency);
bool error = ! openAlsaDevice ( m_hCapture , m_CaptureFormat , dev . ascii ( ) , SND_PCM_STREAM_CAPTURE , SND_PCM_NONBLOCK , m_CaptureLatency ) ;
bool error = ! openAlsaDevice ( m_hCapture , m_CaptureFormat , dev . ascii ( ) , SND_PCM_STREAM_CAPTURE , SND_PCM_NONBLOCK , m_CaptureLatency ) ;
@ -733,19 +733,19 @@ bool AlsaSoundDevice::openAlsaDevice(snd_pcm_t *&alsa_handle, SoundFormat &forma
/* OPEN */
/* OPEN */
if ( ! error & & snd_pcm_open ( & alsa_handle , pcm_name , stream , flags ) < 0 ) {
if ( ! error & & snd_pcm_open ( & alsa_handle , pcm_name , stream , flags ) < 0 ) {
logError ( i18n ( " ALSA Plugin: Error opening PCM device %1 " ) . arg( pcm_name ) ) ;
logError ( i18n ( " ALSA Plugin: Error opening PCM device %1 " ) . tq arg( pcm_name ) ) ;
error = true ;
error = true ;
}
}
if ( ! error & & snd_pcm_hw_params_any ( alsa_handle , hwparams ) < 0 ) {
if ( ! error & & snd_pcm_hw_params_any ( alsa_handle , hwparams ) < 0 ) {
logError ( i18n ( " ALSA Plugin: Can not configure PCM device %1 " ) . arg( pcm_name ) ) ;
logError ( i18n ( " ALSA Plugin: Can not configure PCM device %1 " ) . tq arg( pcm_name ) ) ;
error = true ;
error = true ;
}
}
/* interleaved access type */
/* interleaved access type */
if ( ! error & & snd_pcm_hw_params_set_access ( alsa_handle , hwparams , SND_PCM_ACCESS_RW_INTERLEAVED ) < 0 ) {
if ( ! error & & snd_pcm_hw_params_set_access ( alsa_handle , hwparams , SND_PCM_ACCESS_RW_INTERLEAVED ) < 0 ) {
logError ( i18n ( " ALSA Plugin: Error setting access for %1 " ) . arg( pcm_name ) ) ;
logError ( i18n ( " ALSA Plugin: Error setting access for %1 " ) . tq arg( pcm_name ) ) ;
error = true ;
error = true ;
}
}
@ -755,30 +755,30 @@ bool AlsaSoundDevice::openAlsaDevice(snd_pcm_t *&alsa_handle, SoundFormat &forma
! format . m_IsSigned ,
! format . m_IsSigned ,
format . m_Endianess = = BIG_ENDIAN ) ;
format . m_Endianess = = BIG_ENDIAN ) ;
if ( ! error & & snd_pcm_hw_params_set_format ( alsa_handle , hwparams , sample_format ) < 0 ) {
if ( ! error & & snd_pcm_hw_params_set_format ( alsa_handle , hwparams , sample_format ) < 0 ) {
logError ( i18n ( " ALSA Plugin: Error setting sample format for %1 " ) . arg( pcm_name ) ) ;
logError ( i18n ( " ALSA Plugin: Error setting sample format for %1 " ) . tq arg( pcm_name ) ) ;
error = true ;
error = true ;
}
}
/* channels */
/* channels */
if ( ! error & & snd_pcm_hw_params_set_channels ( alsa_handle , hwparams , format . m_Channels ) < 0 ) {
if ( ! error & & snd_pcm_hw_params_set_channels ( alsa_handle , hwparams , format . m_Channels ) < 0 ) {
logError ( i18n ( " ALSA Plugin: Error setting channels for %1 " ) . arg( pcm_name ) ) ;
logError ( i18n ( " ALSA Plugin: Error setting channels for %1 " ) . tq arg( pcm_name ) ) ;
error = true ;
error = true ;
}
}
/* sample rate */
/* sample rate */
int rate = format . m_SampleRate ;
int rate = format . m_SampleRate ;
if ( ! error & & snd_pcm_hw_params_set_rate_near ( alsa_handle , hwparams , & format . m_SampleRate , & dir ) < 0 ) {
if ( ! error & & snd_pcm_hw_params_set_rate_near ( alsa_handle , hwparams , & format . m_SampleRate , & dir ) < 0 ) {
logError ( i18n ( " ALSA Plugin: Error setting rate for %1 " ) . arg( pcm_name ) ) ;
logError ( i18n ( " ALSA Plugin: Error setting rate for %1 " ) . tq arg( pcm_name ) ) ;
error = true ;
error = true ;
}
}
if ( ! error & & format . m_SampleRate ! = format . m_SampleRate ) {
if ( ! error & & format . m_SampleRate ! = format . m_SampleRate ) {
logWarning ( i18n ( " ALSA Plugin: The rate %1 Hz is not supported by your hardware %2. Using %3 Hz instead " ) . arg( rate ) . arg( pcm_name ) . arg( format . m_SampleRate ) ) ;
logWarning ( i18n ( " ALSA Plugin: The rate %1 Hz is not supported by your hardware %2. Using %3 Hz instead " ) . tq arg( rate ) . tq arg( pcm_name ) . tq arg( format . m_SampleRate ) ) ;
}
}
snd_pcm_uframes_t period_size = m_HWBufferSize / format . frameSize ( ) ;
snd_pcm_uframes_t period_size = m_HWBufferSize / format . frameSize ( ) ;
if ( ! error & & snd_pcm_hw_params_set_period_size_near ( alsa_handle , hwparams , & period_size , & dir ) < 0 ) {
if ( ! error & & snd_pcm_hw_params_set_period_size_near ( alsa_handle , hwparams , & period_size , & dir ) < 0 ) {
logError ( i18n ( " ALSA Plugin: Error setting period size for %1 " ) . arg( pcm_name ) ) ;
logError ( i18n ( " ALSA Plugin: Error setting period size for %1 " ) . tq arg( pcm_name ) ) ;
error = true ;
error = true ;
}
}
@ -788,7 +788,7 @@ bool AlsaSoundDevice::openAlsaDevice(snd_pcm_t *&alsa_handle, SoundFormat &forma
//
//
// /* fragments */
// /* fragments */
// if (!error && snd_pcm_hw_params_set_periods(alsa_handle, hwparams, periods, 0) < 0) {
// if (!error && snd_pcm_hw_params_set_periods(alsa_handle, hwparams, periods, 0) < 0) {
// logError(i18n("ALSA Plugin: Error setting periods for %1"). arg(pcm_name));
// logError(i18n("ALSA Plugin: Error setting periods for %1"). tq arg(pcm_name));
// error = true;
// error = true;
// }
// }
@ -798,17 +798,17 @@ bool AlsaSoundDevice::openAlsaDevice(snd_pcm_t *&alsa_handle, SoundFormat &forma
// if (!error && snd_pcm_hw_params_set_buffer_size_near(alsa_handle, hwparams, &exact_buffersize_frames) < 0) {
// if (!error && snd_pcm_hw_params_set_buffer_size_near(alsa_handle, hwparams, &exact_buffersize_frames) < 0) {
// exact_buffersize_frames = 4096;
// exact_buffersize_frames = 4096;
// if (!error && snd_pcm_hw_params_set_buffer_size_near(alsa_handle, hwparams, &exact_buffersize_frames) < 0) {
// if (!error && snd_pcm_hw_params_set_buffer_size_near(alsa_handle, hwparams, &exact_buffersize_frames) < 0) {
// logError(i18n("ALSA Plugin: Error setting buffersize for %1"). arg(pcm_name));
// logError(i18n("ALSA Plugin: Error setting buffersize for %1"). tq arg(pcm_name));
// error = true;
// error = true;
// }
// }
// }
// }
// size_t exact_buffersize = exact_buffersize_frames * format.frameSize();
// size_t exact_buffersize = exact_buffersize_frames * format.frameSize();
// if (!error && m_HWBufferSize != exact_buffersize) {
// if (!error && m_HWBufferSize != exact_buffersize) {
// logWarning(i18n("ALSA Plugin: Hardware %1 does not support buffer size of %2. Using buffer size of %3 instead."). arg(pcm_name).arg(m_HWBufferSize).arg(exact_buffersize));
// logWarning(i18n("ALSA Plugin: Hardware %1 does not support buffer size of %2. Using buffer size of %3 instead."). tq arg(pcm_name).tq arg(m_HWBufferSize).tq arg(exact_buffersize));
// size_t tmp = (((m_HWBufferSize - 1) / exact_buffersize) + 1) * exact_buffersize;
// size_t tmp = (((m_HWBufferSize - 1) / exact_buffersize) + 1) * exact_buffersize;
// setHWBufferSize(tmp);
// setHWBufferSize(tmp);
// logInfo(i18n("ALSA Plugin: adjusted buffer size for %1 to %2 bytes"). arg(pcm_name).arg(TQString::number(tmp)));
// logInfo(i18n("ALSA Plugin: adjusted buffer size for %1 to %2 bytes"). tq arg(pcm_name).tq arg(TQString::number(tmp)));
// }
// }
/* set all params */
/* set all params */
@ -819,7 +819,7 @@ bool AlsaSoundDevice::openAlsaDevice(snd_pcm_t *&alsa_handle, SoundFormat &forma
}
}
if ( ! error & & snd_pcm_hw_params_get_period_size ( hwparams , & period_size , & dir ) < 0 ) {
if ( ! error & & snd_pcm_hw_params_get_period_size ( hwparams , & period_size , & dir ) < 0 ) {
logError ( i18n ( " ALSA Plugin: Error getting period size for %1 " ) . arg( pcm_name ) ) ;
logError ( i18n ( " ALSA Plugin: Error getting period size for %1 " ) . tq arg( pcm_name ) ) ;
error = true ;
error = true ;
}
}
@ -924,18 +924,18 @@ bool AlsaSoundDevice::openMixerDevice(snd_mixer_t *&mixer_handle, int card, bool
bool attached = false ;
bool attached = false ;
if ( ! error ) {
if ( ! error ) {
if ( snd_mixer_attach ( mixer_handle , cardid . ascii ( ) ) < 0 ) {
if ( snd_mixer_attach ( mixer_handle , cardid . ascii ( ) ) < 0 ) {
staticLogError ( i18n ( " ALSA Plugin: ERROR: snd_mixer_attach for card %1 " ) . arg( card ) ) ;
staticLogError ( i18n ( " ALSA Plugin: ERROR: snd_mixer_attach for card %1 " ) . tq arg( card ) ) ;
error = true ;
error = true ;
} else {
} else {
attached = true ;
attached = true ;
}
}
}
}
if ( ! error & & snd_mixer_selem_register ( mixer_handle , NULL , NULL ) < 0 ) {
if ( ! error & & snd_mixer_selem_register ( mixer_handle , NULL , NULL ) < 0 ) {
staticLogError ( i18n ( " ALSA Plugin: Error: snd_mixer_selem_register for card %1 " ) . arg( card ) ) ;
staticLogError ( i18n ( " ALSA Plugin: Error: snd_mixer_selem_register for card %1 " ) . tq arg( card ) ) ;
error = true ;
error = true ;
}
}
if ( ! error & & snd_mixer_load ( mixer_handle ) < 0 ) {
if ( ! error & & snd_mixer_load ( mixer_handle ) < 0 ) {
staticLogError ( i18n ( " ALSA Plugin: Error: snd_mixer_load for card %1 " ) . arg( card ) ) ;
staticLogError ( i18n ( " ALSA Plugin: Error: snd_mixer_load for card %1 " ) . tq arg( card ) ) ;
error = true ;
error = true ;
}
}
if ( mixer_handle ) {
if ( mixer_handle ) {
@ -1003,7 +1003,7 @@ void AlsaSoundDevice::getPlaybackMixerChannels(
TQString name = snd_mixer_selem_id_get_name ( sid ) ;
TQString name = snd_mixer_selem_id_get_name ( sid ) ;
int idx = snd_mixer_selem_id_get_index ( sid ) ;
int idx = snd_mixer_selem_id_get_index ( sid ) ;
if ( idx )
if ( idx )
name = i18n ( " context-mixername-number " , " %1 %2 " ) . arg( name ) . arg( idx ) ;
name = i18n ( " context-mixername-number " , " %1 %2 " ) . tq arg( name ) . tq arg( idx ) ;
if ( snd_mixer_selem_has_playback_volume ( elem ) ) {
if ( snd_mixer_selem_has_playback_volume ( elem ) ) {
ch2id [ name ] = sid ;
ch2id [ name ] = sid ;
retval . append ( name ) ;
retval . append ( name ) ;
@ -1050,7 +1050,7 @@ void AlsaSoundDevice::getCaptureMixerChannels(
TQString name = snd_mixer_selem_id_get_name ( sid ) ;
TQString name = snd_mixer_selem_id_get_name ( sid ) ;
int idx = snd_mixer_selem_id_get_index ( sid ) ;
int idx = snd_mixer_selem_id_get_index ( sid ) ;
if ( idx )
if ( idx )
name = i18n ( " context-mixerelement-name-number " , " %1 %2 " ) . arg( name ) . arg( idx ) ;
name = i18n ( " context-mixerelement-name-number " , " %1 %2 " ) . tq arg( name ) . tq arg( idx ) ;
bool add2all = false ;
bool add2all = false ;
if ( snd_mixer_selem_has_capture_switch ( elem ) ) {
if ( snd_mixer_selem_has_capture_switch ( elem ) ) {
@ -1204,8 +1204,8 @@ float AlsaSoundDevice::readPlaybackMixerVolume(const TQString &channel, bool &mu
}
}
logError ( " AlsaSound::readPlaybackMixerVolume: " +
logError ( " AlsaSound::readPlaybackMixerVolume: " +
i18n ( " error while reading volume from hwplug:%1,%2 " )
i18n ( " error while reading volume from hwplug:%1,%2 " )
. arg( m_PlaybackCard )
. tq arg( m_PlaybackCard )
. arg( m_PlaybackDevice ) ) ;
. tq arg( m_PlaybackDevice ) ) ;
return 0 ;
return 0 ;
}
}
@ -1234,8 +1234,8 @@ float AlsaSoundDevice::readCaptureMixerVolume(const TQString &channel) const
}
}
logError ( " AlsaSound::readCaptureMixerVolume: " +
logError ( " AlsaSound::readCaptureMixerVolume: " +
i18n ( " error while reading volume from hwplug:%1,%2 " )
i18n ( " error while reading volume from hwplug:%1,%2 " )
. arg( m_CaptureCard )
. tq arg( m_CaptureCard )
. arg( m_CaptureDevice ) ) ;
. tq arg( m_CaptureDevice ) ) ;
return 0 ;
return 0 ;
}
}
@ -1267,9 +1267,9 @@ bool AlsaSoundDevice::writePlaybackMixerVolume (const TQString &channel, float &
}
}
logError ( " AlsaSound::writePlaybackMixerVolume: " +
logError ( " AlsaSound::writePlaybackMixerVolume: " +
i18n ( " error while writing volume %1 to hwplug:%2,%3 " )
i18n ( " error while writing volume %1 to hwplug:%2,%3 " )
. arg( vol )
. tq arg( vol )
. arg( m_PlaybackCard )
. tq arg( m_PlaybackCard )
. arg( m_PlaybackDevice ) ) ;
. tq arg( m_PlaybackDevice ) ) ;
return false ;
return false ;
}
}
@ -1302,9 +1302,9 @@ bool AlsaSoundDevice::writeCaptureMixerVolume (const TQString &channel, float &v
}
}
logError ( " AlsaSound::writeCaptureMixerVolume: " +
logError ( " AlsaSound::writeCaptureMixerVolume: " +
i18n ( " error while writing volume %1 to hwplug:%2,%3 " )
i18n ( " error while writing volume %1 to hwplug:%2,%3 " )
. arg( vol )
. tq arg( vol )
. arg( m_CaptureCard )
. tq arg( m_CaptureCard )
. arg( m_CaptureDevice ) ) ;
. tq arg( m_CaptureDevice ) ) ;
return false ;
return false ;
}
}
@ -1325,9 +1325,9 @@ bool AlsaSoundDevice::writeCaptureMixerSwitch (const TQString &channel, bool cap
}
}
logError ( " AlsaSound::writeCaptureMixerSwitch: " +
logError ( " AlsaSound::writeCaptureMixerSwitch: " +
i18n ( " error while setting capture switch %1 for hwplug:%2,%3 " )
i18n ( " error while setting capture switch %1 for hwplug:%2,%3 " )
. arg( channel )
. tq arg( channel )
. arg( m_CaptureCard )
. tq arg( m_CaptureCard )
. arg( m_CaptureDevice ) ) ;
. tq arg( m_CaptureDevice ) ) ;
return false ;
return false ;
}
}
@ -1445,7 +1445,7 @@ void AlsaSoundDevice::setCaptureDevice(int card, int dev)
TQString AlsaSoundDevice : : getSoundStreamClientDescription ( ) const
TQString AlsaSoundDevice : : getSoundStreamClientDescription ( ) const
{
{
return i18n ( " ALSA Sound Device %1 " ) . arg( PluginBase : : name ( ) ) ;
return i18n ( " ALSA Sound Device %1 " ) . tq arg( PluginBase : : name ( ) ) ;
}
}
@ -1520,9 +1520,9 @@ void AlsaSoundDevice::setCaptureMixerSettings(const TQMap<TQString, AlsaConfigMi
// if (m_captureThread) {
// if (m_captureThread) {
// AlsaCaptureEvent *e = static_cast<AlsaCaptureEvent*>(_e);
// AlsaCaptureEvent *e = static_cast<AlsaCaptureEvent*>(_e);
// TQString msg = i18n("ALSA Plugin, device plughw:%1,%2: %3")
// TQString msg = i18n("ALSA Plugin, device plughw:%1,%2: %3")
// . arg(m_CaptureCard)
// . tq arg(m_CaptureCard)
// . arg(m_CaptureDevice)
// . tq arg(m_CaptureDevice)
// . arg(e->message());
// . tq arg(e->message());
// switch (_e->type()) {
// switch (_e->type()) {
// case CaptureError :
// case CaptureError :
// logError(msg);
// logError(msg);