Răsfoiți Sursa

WebVR: Make XR test more robust.

Mugen87 6 ani în urmă
părinte
comite
6b37efa1ab
1 a modificat fișierele cu 1 adăugiri și 1 ștergeri
  1. 1 1
      examples/js/vr/WebVR.js

+ 1 - 1
examples/js/vr/WebVR.js

@@ -131,7 +131,7 @@ var WEBVR = {
 
 		}
 
-		if ( 'xr' in navigator ) {
+		if ( 'xr' in navigator && 'requestDevice' in navigator.xr ) {
 
 			var button = document.createElement( 'button' );
 			button.style.display = 'none';