From cd38d4b9e1c653c36a1c20adbccec97d6806033f Mon Sep 17 00:00:00 2001 From: Vincent Fretin Date: Mon, 26 Dec 2022 21:12:56 +0100 Subject: [PATCH] Hide VR button in desktop mode on iPad (fix #4814) (#5191) --- src/components/scene/vr-mode-ui.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/components/scene/vr-mode-ui.js b/src/components/scene/vr-mode-ui.js index c8e4fd1f881..e9f3e469453 100644 --- a/src/components/scene/vr-mode-ui.js +++ b/src/components/scene/vr-mode-ui.js @@ -135,7 +135,7 @@ module.exports.Component = registerComponent('vr-mode-ui', { var sceneEl = this.el; if (!this.enterVREl) { return; } if (sceneEl.is('vr-mode') || - (sceneEl.isMobile && !this.data.cardboardModeEnabled && !utils.device.checkVRSupport())) { + ((sceneEl.isMobile || utils.device.isMobileDeviceRequestingDesktopSite()) && !this.data.cardboardModeEnabled && !utils.device.checkVRSupport())) { this.enterVREl.classList.add(HIDDEN_CLASS); } else { if (!utils.device.checkVRSupport()) { this.enterVREl.classList.add('fullscreen'); }