repo: janusweb action: commit revision: path_from: revision_from: b20488d3d59ec6940d624243897e7ed510a497ff: path_to: revision_to:
commit b20488d3d59ec6940d624243897e7ed510a497ff Author: James BaicoianuDate: Sat May 8 13:43:04 2021 -0700 Exit pointerlock if still active when menu is shown diff --git a/scripts/janusweb.js b/scripts/janusweb.js
--- a/scripts/janusweb.js
+++ b/scripts/janusweb.js
@@ -681,6 +681,9 @@ console.log('Register new SYSTEM tag type:', tagname, classobj, extendclass);
overlay.hide();
}
}
+ if (document.pointerLockElement) {
+ document.exitPointerLock();
+ }
}
this.isVRActive = function() {
return (typeof XRSession != 'undefined' && this.engine.client.xrsession instanceof XRSession);
-----END OF PAGE-----