summaryrefslogtreecommitdiffstats
path: root/src/multimedia/audio/qaudioinput_alsa_p.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/multimedia/audio/qaudioinput_alsa_p.cpp')
-rw-r--r--src/multimedia/audio/qaudioinput_alsa_p.cpp28
1 files changed, 14 insertions, 14 deletions
diff --git a/src/multimedia/audio/qaudioinput_alsa_p.cpp b/src/multimedia/audio/qaudioinput_alsa_p.cpp
index 9eb8cfb..8a8f0db 100644
--- a/src/multimedia/audio/qaudioinput_alsa_p.cpp
+++ b/src/multimedia/audio/qaudioinput_alsa_p.cpp
@@ -75,7 +75,7 @@ QAudioInputPrivate::QAudioInputPrivate(const QByteArray &device, const QAudioFor
intervalTime = 1000;
audioBuffer = 0;
errorState = QAudio::NoError;
- deviceState = QAudio::StopState;
+ deviceState = QAudio::StoppedState;
audioSource = 0;
pullMode = true;
resuming = false;
@@ -206,7 +206,7 @@ int QAudioInputPrivate::setFormat()
QIODevice* QAudioInputPrivate::start(QIODevice* device)
{
- if(deviceState != QAudio::StopState)
+ if(deviceState != QAudio::StoppedState)
close();
if(!pullMode && audioSource) {
@@ -234,10 +234,10 @@ QIODevice* QAudioInputPrivate::start(QIODevice* device)
void QAudioInputPrivate::stop()
{
- if(deviceState == QAudio::StopState)
+ if(deviceState == QAudio::StoppedState)
return;
- deviceState = QAudio::StopState;
+ deviceState = QAudio::StoppedState;
close();
emit stateChanged(deviceState);
@@ -283,7 +283,7 @@ bool QAudioInputPrivate::open()
}
if (( err < 0)||(handle == 0)) {
errorState = QAudio::OpenError;
- deviceState = QAudio::StopState;
+ deviceState = QAudio::StoppedState;
emit stateChanged(deviceState);
return false;
}
@@ -367,7 +367,7 @@ bool QAudioInputPrivate::open()
if( err < 0) {
qWarning()<<errMessage;
errorState = QAudio::OpenError;
- deviceState = QAudio::StopState;
+ deviceState = QAudio::StoppedState;
emit stateChanged(deviceState);
return false;
}
@@ -413,7 +413,7 @@ bool QAudioInputPrivate::open()
void QAudioInputPrivate::close()
{
- deviceState = QAudio::StopState;
+ deviceState = QAudio::StoppedState;
timer->stop();
if ( handle ) {
@@ -490,7 +490,7 @@ qint64 QAudioInputPrivate::read(char* data, qint64 len)
if(l < 0) {
close();
errorState = QAudio::IOError;
- deviceState = QAudio::StopState;
+ deviceState = QAudio::StoppedState;
emit stateChanged(deviceState);
} else if(l == 0) {
errorState = QAudio::NoError;
@@ -508,7 +508,7 @@ qint64 QAudioInputPrivate::read(char* data, qint64 len)
void QAudioInputPrivate::resume()
{
- if(deviceState == QAudio::SuspendState) {
+ if(deviceState == QAudio::SuspendedState) {
int err = 0;
if(handle) {
@@ -558,7 +558,7 @@ int QAudioInputPrivate::notifyInterval() const
return intervalTime;
}
-qint64 QAudioInputPrivate::totalTime() const
+qint64 QAudioInputPrivate::processedUSecs() const
{
return totalTimeValue;
}
@@ -567,14 +567,14 @@ void QAudioInputPrivate::suspend()
{
if(deviceState == QAudio::ActiveState||resuming) {
timer->stop();
- deviceState = QAudio::SuspendState;
+ deviceState = QAudio::SuspendedState;
emit stateChanged(deviceState);
}
}
void QAudioInputPrivate::userFeed()
{
- if(deviceState == QAudio::StopState || deviceState == QAudio::SuspendState)
+ if(deviceState == QAudio::StoppedState || deviceState == QAudio::SuspendedState)
return;
#ifdef DEBUG_AUDIO
QTime now(QTime::currentTime());
@@ -606,12 +606,12 @@ bool QAudioInputPrivate::deviceReady()
return true;
}
-qint64 QAudioInputPrivate::clock() const
+qint64 QAudioInputPrivate::elapsedUSecs() const
{
if(!handle)
return 0;
- if (deviceState == QAudio::StopState)
+ if (deviceState == QAudio::StoppedState)
return 0;
#if(SND_LIB_MAJOR == 1 && SND_LIB_MINOR == 0 && SND_LIB_SUBMINOR >= 14)