mirror of
https://github.com/lubosz/overte.git
synced 2025-06-02 04:50:31 +02:00
40 lines
1.8 KiB
Diff
40 lines
1.8 KiB
Diff
diff --git a/scripts/simplifiedUI/ui/simplifiedUI.js b/scripts/simplifiedUI/ui/simplifiedUI.js
|
|
index cdf6a9591a..4116eb4314 100644
|
|
--- a/scripts/simplifiedUI/ui/simplifiedUI.js
|
|
+++ b/scripts/simplifiedUI/ui/simplifiedUI.js
|
|
@@ -457,9 +457,16 @@ function onGeometryChanged(rect) {
|
|
}
|
|
}
|
|
|
|
-function ensureFirstPersonCameraInHMD(isHMDMode) {
|
|
+function onDisplayModeChanged(isHMDMode) {
|
|
+ print("TEST 2");
|
|
if (isHMDMode) {
|
|
Camera.setModeString("first person");
|
|
+ } else {
|
|
+ //setTimeout(function () {
|
|
+ toolbar.writeProperty("visible", false);
|
|
+ print("TEST");
|
|
+ //}, 10000);
|
|
+
|
|
}
|
|
}
|
|
|
|
@@ -505,7 +512,7 @@ function startup() {
|
|
updateOutputDeviceMutedOverlay(isOutputMuted());
|
|
Audio.mutedDesktopChanged.connect(onDesktopInputDeviceMutedChanged);
|
|
Window.geometryChanged.connect(onGeometryChanged);
|
|
- HMD.displayModeChanged.connect(ensureFirstPersonCameraInHMD);
|
|
+ HMD.displayModeChanged.connect(onDisplayModeChanged);
|
|
Audio.avatarGainChanged.connect(maybeUpdateOutputDeviceMutedOverlay);
|
|
Audio.localInjectorGainChanged.connect(maybeUpdateOutputDeviceMutedOverlay);
|
|
Audio.serverInjectorGainChanged.connect(maybeUpdateOutputDeviceMutedOverlay);
|
|
@@ -559,7 +566,7 @@ function shutdown() {
|
|
|
|
Audio.mutedDesktopChanged.disconnect(onDesktopInputDeviceMutedChanged);
|
|
Window.geometryChanged.disconnect(onGeometryChanged);
|
|
- HMD.displayModeChanged.disconnect(ensureFirstPersonCameraInHMD);
|
|
+ HMD.displayModeChanged.disconnect(onDisplayModeChanged);
|
|
Audio.avatarGainChanged.disconnect(maybeUpdateOutputDeviceMutedOverlay);
|
|
Audio.localInjectorGainChanged.disconnect(maybeUpdateOutputDeviceMutedOverlay);
|
|
Audio.serverInjectorGainChanged.disconnect(maybeUpdateOutputDeviceMutedOverlay);
|