mirror of
https://github.com/overte-org/overte.git
synced 2025-04-20 14:03:55 +02:00
Fix for HMDTools targeting wrong screen on OSX
This commit is contained in:
parent
fa9dfbe073
commit
de49057f17
1 changed files with 7 additions and 2 deletions
|
@ -162,11 +162,16 @@ void HMDToolsDialog::enterHDMMode() {
|
|||
close();
|
||||
}
|
||||
|
||||
Application::getInstance()->setFullscreen(true);
|
||||
Application::getInstance()->setEnableVRMode(true);
|
||||
|
||||
const int SLIGHT_DELAY = 500;
|
||||
QTimer::singleShot(SLIGHT_DELAY, this, SLOT(activateWindowAfterEnterMode()));
|
||||
// If we go to fullscreen immediately, it ends up on the primary monitor,
|
||||
// even though we've already moved the window. By adding this delay, the
|
||||
// fullscreen target screen ends up correct.
|
||||
QTimer::singleShot(SLIGHT_DELAY, this, [&]{
|
||||
Application::getInstance()->setFullscreen(true);
|
||||
activateWindowAfterEnterMode();
|
||||
});
|
||||
|
||||
_inHDMMode = true;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue