Remove AudioDeviceObserver and make ADM not inherit from the Module interface.
(Re-upload of https://codereview.webrtc.org/3020493002/) Bug: webrtc:4690, webrtc:7306 Change-Id: I67fb9ebca1296aabc08eae8a292a5c69832dc35e Reviewed-on: https://webrtc-review.googlesource.com/5360 Commit-Queue: Fredrik Solenberg <solenberg@webrtc.org> Reviewed-by: Henrik Andreassson <henrika@webrtc.org> Cr-Commit-Position: refs/heads/master@{#20083}
This commit is contained in:
committed by
Commit Bot
parent
c007857ab9
commit
34cdd2d402
@ -89,11 +89,7 @@ AudioDeviceLinuxALSA::AudioDeviceLinuxALSA() :
|
||||
_playIsInitialized(false),
|
||||
_AGC(false),
|
||||
_recordingDelay(0),
|
||||
_playoutDelay(0),
|
||||
_playWarning(0),
|
||||
_playError(0),
|
||||
_recWarning(0),
|
||||
_recError(0)
|
||||
_playoutDelay(0)
|
||||
{
|
||||
memset(_oldKeyState, 0, sizeof(_oldKeyState));
|
||||
LOG(LS_INFO) << __FUNCTION__ << " created";
|
||||
@ -166,10 +162,6 @@ AudioDeviceGeneric::InitStatus AudioDeviceLinuxALSA::Init() {
|
||||
<< "failed to open X display, typing detection will not work";
|
||||
}
|
||||
#endif
|
||||
_playWarning = 0;
|
||||
_playError = 0;
|
||||
_recWarning = 0;
|
||||
_recError = 0;
|
||||
|
||||
_initialized = true;
|
||||
|
||||
@ -1014,8 +1006,6 @@ int32_t AudioDeviceLinuxALSA::InitPlayout()
|
||||
_handlePlayout, _playoutFramesIn10MS);
|
||||
|
||||
// Init varaibles used for play
|
||||
_playWarning = 0;
|
||||
_playError = 0;
|
||||
|
||||
if (_handlePlayout != NULL)
|
||||
{
|
||||
@ -1447,54 +1437,6 @@ bool AudioDeviceLinuxALSA::Playing() const
|
||||
return (_playing);
|
||||
}
|
||||
|
||||
bool AudioDeviceLinuxALSA::PlayoutWarning() const
|
||||
{
|
||||
rtc::CritScope lock(&_critSect);
|
||||
return (_playWarning > 0);
|
||||
}
|
||||
|
||||
bool AudioDeviceLinuxALSA::PlayoutError() const
|
||||
{
|
||||
rtc::CritScope lock(&_critSect);
|
||||
return (_playError > 0);
|
||||
}
|
||||
|
||||
bool AudioDeviceLinuxALSA::RecordingWarning() const
|
||||
{
|
||||
rtc::CritScope lock(&_critSect);
|
||||
return (_recWarning > 0);
|
||||
}
|
||||
|
||||
bool AudioDeviceLinuxALSA::RecordingError() const
|
||||
{
|
||||
rtc::CritScope lock(&_critSect);
|
||||
return (_recError > 0);
|
||||
}
|
||||
|
||||
void AudioDeviceLinuxALSA::ClearPlayoutWarning()
|
||||
{
|
||||
rtc::CritScope lock(&_critSect);
|
||||
_playWarning = 0;
|
||||
}
|
||||
|
||||
void AudioDeviceLinuxALSA::ClearPlayoutError()
|
||||
{
|
||||
rtc::CritScope lock(&_critSect);
|
||||
_playError = 0;
|
||||
}
|
||||
|
||||
void AudioDeviceLinuxALSA::ClearRecordingWarning()
|
||||
{
|
||||
rtc::CritScope lock(&_critSect);
|
||||
_recWarning = 0;
|
||||
}
|
||||
|
||||
void AudioDeviceLinuxALSA::ClearRecordingError()
|
||||
{
|
||||
rtc::CritScope lock(&_critSect);
|
||||
_recError = 0;
|
||||
}
|
||||
|
||||
// ============================================================================
|
||||
// Private Methods
|
||||
// ============================================================================
|
||||
|
||||
Reference in New Issue
Block a user