mirror of
https://github.com/AleziaKurdis/overte.git
synced 2025-04-08 06:32:35 +02:00
Fix invalid state transition in desktop mode
This commit is contained in:
parent
fc78d0582e
commit
1088a0f9ae
1 changed files with 4 additions and 2 deletions
|
@ -980,7 +980,7 @@
|
|||
return;
|
||||
}
|
||||
|
||||
if (message.action === "grab" && message.grabbedEntity === HMD.tabletID) {
|
||||
if (message.action === "grab" && message.grabbedEntity === HMD.tabletID && HMD.active) {
|
||||
// Tablet may have been grabbed after it replaced expanded mini tablet.
|
||||
miniState.setState(miniState.MINI_HIDDEN);
|
||||
} else if (message.action === "grab" && miniState.getState() === miniState.MINI_VISIBLE) {
|
||||
|
@ -992,7 +992,9 @@
|
|||
|
||||
function onWentAway() {
|
||||
// Mini tablet only available when user is not away.
|
||||
miniState.setState(miniState.MINI_HIDDEN);
|
||||
if (HMD.active) {
|
||||
miniState.setState(miniState.MINI_HIDDEN);
|
||||
}
|
||||
}
|
||||
|
||||
function onDisplayModeChanged() {
|
||||
|
|
Loading…
Reference in a new issue