From 47627fd1debfe53ad692450aa94f373a845ce90d Mon Sep 17 00:00:00 2001 From: Zach Fox Date: Mon, 30 Apr 2018 15:02:20 -0700 Subject: [PATCH] Fix edge case --- .../marketplace/spectator-camera/SpectatorCamera.qml | 5 ----- .../marketplace/spectator-camera/spectatorCamera.js | 3 +-- 2 files changed, 1 insertion(+), 7 deletions(-) diff --git a/unpublishedScripts/marketplace/spectator-camera/SpectatorCamera.qml b/unpublishedScripts/marketplace/spectator-camera/SpectatorCamera.qml index 30a30e283e..568c1faf3c 100644 --- a/unpublishedScripts/marketplace/spectator-camera/SpectatorCamera.qml +++ b/unpublishedScripts/marketplace/spectator-camera/SpectatorCamera.qml @@ -517,11 +517,6 @@ Rectangle { takeSnapshotFromControllerCheckBox.visible = false; } break; - case 'showPreviewTextureNotInstructions': - console.log('showPreviewTextureNotInstructions recvd', JSON.stringify(message)); - spectatorCameraPreview.url = message.url; - spectatorCameraPreview.visible = message.setting; - break; case 'enable360SnapshotButton': take360SnapshotButton.text = "Take 360 Snapshot"; take360SnapshotButton.enabled = cameraToggleButton.camIsOn; diff --git a/unpublishedScripts/marketplace/spectator-camera/spectatorCamera.js b/unpublishedScripts/marketplace/spectator-camera/spectatorCamera.js index 736a9a2688..56a946c682 100644 --- a/unpublishedScripts/marketplace/spectator-camera/spectatorCamera.js +++ b/unpublishedScripts/marketplace/spectator-camera/spectatorCamera.js @@ -242,7 +242,6 @@ function setDisplay(showCameraView) { var url = (camera) ? (showCameraView ? "resource://spectatorCameraFrame" : "resource://hmdPreviewFrame") : ""; - sendToQml({ method: 'showPreviewTextureNotInstructions', setting: !!url, url: url }); // FIXME: temporary hack to avoid setting the display texture to hmdPreviewFrame // until it is the correct mono. @@ -255,11 +254,11 @@ const MONITOR_SHOWS_CAMERA_VIEW_DEFAULT = false; var monitorShowsCameraView = !!Settings.getValue('spectatorCamera/monitorShowsCameraView', MONITOR_SHOWS_CAMERA_VIEW_DEFAULT); function setMonitorShowsCameraView(showCameraView) { + setDisplay(showCameraView); if (showCameraView === monitorShowsCameraView) { return; } monitorShowsCameraView = showCameraView; - setDisplay(showCameraView); Settings.setValue('spectatorCamera/monitorShowsCameraView', showCameraView); } function setMonitorShowsCameraViewAndSendToQml(showCameraView) {