Skip to content

Commit

Permalink
remove unnecessary html canvas in example
Browse files Browse the repository at this point in the history
  • Loading branch information
Guillaume227 authored and ben-clayton committed Apr 11, 2023
1 parent 38743a4 commit e5ffc99
Showing 1 changed file with 0 additions and 15 deletions.
15 changes: 0 additions & 15 deletions examples/shell.emscripten.html
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,6 @@
.emscripten { padding-right: 0; margin-left: auto; margin-right: auto; display: block; }
div.emscripten { text-align: center; }
div.emscripten_border { border: 1px solid black; }
/* the canvas *must not* have any border or padding, or mouse coords will be wrong */
canvas.emscripten { border: 0px none; background-color: black; }

#emscripten_logo {
display: inline-block;
Expand Down Expand Up @@ -111,9 +109,6 @@
</div>


<div class="emscripten_border">
<canvas class="emscripten" id="canvas" oncontextmenu="event.preventDefault()" tabindex=-1></canvas>
</div>
<textarea id="output" rows="8"></textarea>

<script type='text/javascript'>
Expand Down Expand Up @@ -141,16 +136,6 @@
}
};
})(),
canvas: (function() {
var canvas = document.getElementById('canvas');

// 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
canvas.addEventListener("webglcontextlost", function(e) { alert('WebGL context lost. You will need to reload the page.'); e.preventDefault(); }, false);

return canvas;
})(),
setStatus: function(text) {
if (!Module.setStatus.last) Module.setStatus.last = { time: Date.now(), text: '' };
if (text === Module.setStatus.last.text) return;
Expand Down

0 comments on commit e5ffc99

Please sign in to comment.