mirror of
https://github.com/overte-org/overte.git
synced 2025-08-06 22:39:18 +02:00
Merge pull request #14536 from danteruiz/fix-audio-switching
Respect changed audio settings when switch displays (Master)
This commit is contained in:
commit
e8c1c4a27b
1 changed files with 5 additions and 0 deletions
|
@ -6504,11 +6504,16 @@ void Application::resetSensors(bool andReload) {
|
||||||
}
|
}
|
||||||
|
|
||||||
void Application::hmdVisibleChanged(bool visible) {
|
void Application::hmdVisibleChanged(bool visible) {
|
||||||
|
// TODO
|
||||||
|
// calling start and stop will change audio input and ouput to default audio devices.
|
||||||
|
// we need to add a pause/unpause functionality to AudioClient for this to work properly
|
||||||
|
#if 0
|
||||||
if (visible) {
|
if (visible) {
|
||||||
QMetaObject::invokeMethod(DependencyManager::get<AudioClient>().data(), "start", Qt::QueuedConnection);
|
QMetaObject::invokeMethod(DependencyManager::get<AudioClient>().data(), "start", Qt::QueuedConnection);
|
||||||
} else {
|
} else {
|
||||||
QMetaObject::invokeMethod(DependencyManager::get<AudioClient>().data(), "stop", Qt::QueuedConnection);
|
QMetaObject::invokeMethod(DependencyManager::get<AudioClient>().data(), "stop", Qt::QueuedConnection);
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
void Application::updateWindowTitle() const {
|
void Application::updateWindowTitle() const {
|
||||||
|
|
Loading…
Reference in a new issue