diff options
Diffstat (limited to 'modules')
-rw-r--r-- | modules/webxr/native/library_godot_webxr.js | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/modules/webxr/native/library_godot_webxr.js b/modules/webxr/native/library_godot_webxr.js index 722b448fd5..031530a047 100644 --- a/modules/webxr/native/library_godot_webxr.js +++ b/modules/webxr/native/library_godot_webxr.js @@ -67,7 +67,8 @@ const GodotWebXR = { GodotWebXR.orig_requestAnimationFrame = Browser.requestAnimationFrame; } Browser.requestAnimationFrame = enable - ? GodotWebXR.requestAnimationFrame : GodotWebXR.orig_requestAnimationFrame; + ? GodotWebXR.requestAnimationFrame + : GodotWebXR.orig_requestAnimationFrame; }, pauseResumeMainLoop: () => { // Once both GodotWebXR.session and GodotWebXR.space are set or @@ -76,9 +77,9 @@ const GodotWebXR = { // gets picked up automatically, however, in the Oculus Browser // on the Quest, we need to pause and resume the main loop. Browser.mainLoop.pause(); - runtimeKeepalivePush(); // eslint-disable-line no-undef + runtimeKeepalivePush(); window.setTimeout(function () { - runtimeKeepalivePop(); // eslint-disable-line no-undef + runtimeKeepalivePop(); Browser.mainLoop.resume(); }, 0); }, @@ -287,12 +288,12 @@ const GodotWebXR = { // Store onsimpleevent so we can use it later. GodotWebXR.onsimpleevent = onsimpleevent; - const gl_context_handle = _emscripten_webgl_get_current_context(); // eslint-disable-line no-undef + const gl_context_handle = _emscripten_webgl_get_current_context(); const gl = GL.getContext(gl_context_handle).GLctx; GodotWebXR.gl = gl; gl.makeXRCompatible().then(function () { - GodotWebXR.gl_binding = new XRWebGLBinding(session, gl); // eslint-disable-line no-undef + GodotWebXR.gl_binding = new XRWebGLBinding(session, gl); // This will trigger the layer to get created. GodotWebXR.getLayer(); |