From 01efde3d365dd37246a24b19f4bb3098b1e340eb Mon Sep 17 00:00:00 2001 From: Ville Helin Date: Wed, 3 Feb 2021 13:38:41 +0200 Subject: [PATCH] Filebrowser now opens instantly, not after the user clicks on a random point on screen --- .../Plugins/StandaloneFileBrowser.jslib | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/Assets/StandaloneFileBrowser/Plugins/StandaloneFileBrowser.jslib b/Assets/StandaloneFileBrowser/Plugins/StandaloneFileBrowser.jslib index 1198f38..bafbe36 100644 --- a/Assets/StandaloneFileBrowser/Plugins/StandaloneFileBrowser.jslib +++ b/Assets/StandaloneFileBrowser/Plugins/StandaloneFileBrowser.jslib @@ -48,10 +48,7 @@ var StandaloneFileBrowserWebGLPlugin = { } document.body.appendChild(fileInput); - document.onmouseup = function() { - fileInput.click(); - document.onmouseup = null; - } + fileInput.click(); }, // Save file