diff options
Diffstat (limited to 'examples/multimedia')
-rw-r--r-- | examples/multimedia/audioinput/audioinput.cpp | 9 | ||||
-rw-r--r-- | examples/multimedia/audioinput/audioinput.h | 4 |
2 files changed, 7 insertions, 6 deletions
diff --git a/examples/multimedia/audioinput/audioinput.cpp b/examples/multimedia/audioinput/audioinput.cpp index 2258854..8a97640 100644 --- a/examples/multimedia/audioinput/audioinput.cpp +++ b/examples/multimedia/audioinput/audioinput.cpp @@ -279,14 +279,15 @@ void InputTest::initializeAudio() void InputTest::createAudioInput() { + m_audioInput = new QAudioInput(m_device, m_format, this); - connect(m_audioInput, SIGNAL(notify()), SLOT(status())); - connect(m_audioInput, SIGNAL(stateChanged(QAudio::State)), SLOT(state(QAudio::State))); + connect(m_audioInput, SIGNAL(notify()), SLOT(notified())); + connect(m_audioInput, SIGNAL(stateChanged(QAudio::State)), SLOT(stateChanged(QAudio::State))); m_audioInfo->start(); m_audioInput->start(m_audioInfo); } -void InputTest::status() +void InputTest::notified() { qWarning() << "bytesReady = " << m_audioInput->bytesReady() << ", " << "elapsedUSecs = " <<m_audioInput->elapsedUSecs() @@ -345,7 +346,7 @@ void InputTest::toggleSuspend() } } -void InputTest::state(QAudio::State state) +void InputTest::stateChanged(QAudio::State state) { qWarning() << "state = " << state; } diff --git a/examples/multimedia/audioinput/audioinput.h b/examples/multimedia/audioinput/audioinput.h index f1ab254..f87c682 100644 --- a/examples/multimedia/audioinput/audioinput.h +++ b/examples/multimedia/audioinput/audioinput.h @@ -105,11 +105,11 @@ private: private slots: void refreshDisplay(); - void status(); + void notified(); void readMore(); void toggleMode(); void toggleSuspend(); - void state(QAudio::State state); + void stateChanged(QAudio::State state); void deviceChanged(int index); private: |