Browse Source

Platform: don't assume canvas is in all windowless Emscripten apps.

Some apps might not use GL context at all.
pull/217/head
Vladimír Vondruš 9 years ago
parent
commit
3cae6a4a86
  1. 2
      src/Magnum/Platform/WindowlessEmscriptenApplication.js

2
src/Magnum/Platform/WindowlessEmscriptenApplication.js

@ -57,6 +57,6 @@ for(var i = 0; i != args.length; ++i) {
Module.setStatus('Downloading...');
Module.canvas.addEventListener('contextmenu', function(event) {
if(Module.canvas) Module.canvas.addEventListener('contextmenu', function(event) {
event.preventDefault();
}, true);

Loading…
Cancel
Save