Bug 1374399 - Enable WebVR by default for macOS
MozReview-Commit-ID: JWJlw7Qib36
--- a/modules/libpref/init/all.js
+++ b/modules/libpref/init/all.js
@@ -5256,17 +5256,17 @@ pref("jsloader.shareGlobal", true);
// event loop to become idle before actually taking the screenshot.
pref("dom.browserElement.maxScreenshotDelayMS", 2000);
// Whether we should show the placeholder when the element is focused but empty.
pref("dom.placeholder.show_on_focus", true);
// WebVR is enabled by default in beta and release for Windows and for all
// platforms in nightly and aurora.
-#if defined(XP_WIN) || !defined(RELEASE_OR_BETA)
+#if defined(XP_WIN) || defined(XP_MACOSX) || !defined(RELEASE_OR_BETA)
pref("dom.vr.enabled", true);
#else
pref("dom.vr.enabled", false);
#endif
// It is often desirable to automatically start vr presentation when
// a user puts on the VR headset. This is done by emitting the
// Window.vrdisplayactivate event when the headset's sensors detect it
// being worn. This can result in WebVR content taking over the headset
@@ -5303,21 +5303,24 @@ pref("dom.vr.oculus.present.timeout", 10
// Oculus requests that we shut down and unload the OVR library, by setting
// a "ShouldQuit" flag. To ensure that we don't interfere with
// Oculus software auto-updates, we will not attempt to re-load the
// OVR library until this timeout has elapsed.
pref("dom.vr.oculus.quit.timeout", 30000);
// OSVR device
pref("dom.vr.osvr.enabled", false);
// OpenVR device
-#if defined(XP_WIN) && defined(HAVE_64BIT_BUILD)
+#if !defined(HAVE_64BIT_BUILD)
// We are only enabling WebVR by default on 64-bit builds (Bug 1384459)
+pref("dom.vr.openvr.enabled", false);
+#elif defined(XP_WIN) || defined(XP_MACOSX)
+// We enable WebVR by default for Windows and macOS
pref("dom.vr.openvr.enabled", true);
#else
-// See Bug 1310663 (Linux) and Bug 1310665 (macOS)
+// See Bug 1310663 (Linux)
pref("dom.vr.openvr.enabled", false);
#endif
// Pose prediction reduces latency effects by returning future predicted HMD
// poses to callers of the WebVR API. This currently only has an effect for
// Oculus Rift on SDK 0.8 or greater.
pref("dom.vr.poseprediction.enabled", true);
// Starting VR presentation is only allowed within a user gesture or event such
// as VRDisplayActivate triggered by the system. dom.vr.require-gesture allows