From 5530c222b5161292e4be782b6c0a8e44dca9d71b Mon Sep 17 00:00:00 2001 From: Ilya Shurumov Date: Fri, 9 Jul 2021 21:50:49 +0600 Subject: [PATCH] - web shell misc stuff --- src_rebuild/platform/Emscripten/shell.html | 25 +++++++++++++++++----- 1 file changed, 20 insertions(+), 5 deletions(-) diff --git a/src_rebuild/platform/Emscripten/shell.html b/src_rebuild/platform/Emscripten/shell.html index b224f8b2..df805bb6 100644 --- a/src_rebuild/platform/Emscripten/shell.html +++ b/src_rebuild/platform/Emscripten/shell.html @@ -97,9 +97,11 @@

See REDRIVER2 wiki for controls

- - - (.ISO, .BIN, .CCD)  +
+ + + (.ISO, .BIN, .CCD)  +
@@ -115,6 +117,7 @@ postRun: [], print: (function () { var element = document.getElementById('output'); + if (element) element.value = ''; // clear browser cache return function (text) { if (arguments.length > 1) text = Array.prototype.slice.call(arguments).join(' '); @@ -136,7 +139,7 @@ }, canvas: (function () { var canvas = document.getElementById('canvas'); - + canvas.style.display = "none"; // As a default initial behavior, pop up an alert when webgl context is lost. To make your // application robust, you may want to override this behavior before shipping! // See http://www.khronos.org/registry/webgl/specs/latest/1.0/#5.15.2 @@ -178,7 +181,7 @@ // don't immediately run the game Module['noInitialRun'] = true - // for save data + // for save config/data Module.preRun.push(function() { ENV.HOME = "/userstorage"; @@ -204,12 +207,24 @@ Module.ccall('WebLoadCDImage', 'null', ['number', 'number'], [data, size]); callMain(); + + var element = document.getElementById('startup_panel'); + element.style.display = "none"; + + var canvas = document.getElementById('canvas'); + canvas.style.display = null; }; reader.readAsArrayBuffer(event.target.files[0]); } function runDemo() { callMain(["-ini", "demo_config.ini"]); + + var element = document.getElementById('startup_panel'); + element.style.display = "none"; + + var canvas = document.getElementById('canvas'); + canvas.style.display = null; }