1
0
mirror of https://github.com/qTox/qTox.git synced 2024-03-22 14:00:36 +08:00

fix: [un]subscribe output in avform

Fix sound test on AV settings tab
This commit is contained in:
Diadlo 2018-01-16 01:59:53 +03:00
parent c41de48a6b
commit 8c05399e41
No known key found for this signature in database
GPG Key ID: 5AF9F2E29107C727
2 changed files with 3 additions and 0 deletions

View File

@ -117,6 +117,7 @@ void AVForm::hideEvent(QHideEvent* event)
{
if (subscribedToAudioIn) {
// TODO: This should not be done in show/hide events
audio->unsubscribeOutput(alSource);
audio->unsubscribeInput();
subscribedToAudioIn = false;
}
@ -139,6 +140,7 @@ void AVForm::showEvent(QShowEvent* event)
if (!subscribedToAudioIn) {
// TODO: This should not be done in show/hide events
audio->subscribeOutput(alSource);
audio->subscribeInput();
subscribedToAudioIn = true;
}

View File

@ -102,6 +102,7 @@ private:
CameraSource& camera;
QVector<QPair<QString, QString>> videoDeviceList;
QVector<VideoMode> videoModes;
uint alSource;
};
#endif