diff options
author | Roman Beltiukov <maybe.hello.world@gmail.com> | 2023-05-25 22:10:10 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-05-25 22:10:10 +0000 |
commit | b2530c965c2afd5512c5f9020251fd4be8f067e5 (patch) | |
tree | 0c1620e00ac4eddea514706a5c3bf3e03bd46c70 /javascript/imageviewerGamepad.js | |
parent | 09d9c3d287ee4543d285e0fde8b81603c9751a7e (diff) | |
parent | a6e653be26cc05f4438145fa0082816e9fbbf5fc (diff) | |
download | stable-diffusion-webui-gfx803-b2530c965c2afd5512c5f9020251fd4be8f067e5.tar.gz stable-diffusion-webui-gfx803-b2530c965c2afd5512c5f9020251fd4be8f067e5.tar.bz2 stable-diffusion-webui-gfx803-b2530c965c2afd5512c5f9020251fd4be8f067e5.zip |
Merge branch 'dev' into master
Diffstat (limited to 'javascript/imageviewerGamepad.js')
-rw-r--r-- | javascript/imageviewerGamepad.js | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/javascript/imageviewerGamepad.js b/javascript/imageviewerGamepad.js index 6297a12b..31d226de 100644 --- a/javascript/imageviewerGamepad.js +++ b/javascript/imageviewerGamepad.js @@ -1,7 +1,7 @@ window.addEventListener('gamepadconnected', (e) => { const index = e.gamepad.index; let isWaiting = false; - setInterval(async () => { + setInterval(async() => { if (!opts.js_modal_lightbox_gamepad || isWaiting) return; const gamepad = navigator.getGamepads()[index]; const xValue = gamepad.axes[0]; @@ -14,7 +14,7 @@ window.addEventListener('gamepadconnected', (e) => { } if (isWaiting) { await sleepUntil(() => { - const xValue = navigator.getGamepads()[index].axes[0] + const xValue = navigator.getGamepads()[index].axes[0]; if (xValue < 0.3 && xValue > -0.3) { return true; } |