Browse Source

Platform: this likely should have been `module` also.

I have no idea what is gping on in the JS land and why there's always 76
ways to do a certain thing, but since everything else in this file is
accessing members via `module.` and not `this.`, these variable accesses
likely should do the same.
master
Vladimír Vondruš 1 month ago
parent
commit
0ff15f2872
  1. 4
      src/Magnum/Platform/EmscriptenApplication.js
  2. 4
      src/Magnum/Platform/WindowlessEmscriptenApplication.js

4
src/Magnum/Platform/EmscriptenApplication.js

@ -73,11 +73,11 @@ function createMagnumModule(init) {
totalDependencies: 0,
monitorRunDependencies: function(left) {
this.totalDependencies = Math.max(this.totalDependencies, left);
module.totalDependencies = Math.max(module.totalDependencies, left);
if(left) {
module.setStatus('Downloading...');
module.setStatusDescription((this.totalDependencies - left) + ' / ' + this.totalDependencies);
module.setStatusDescription((module.totalDependencies - left) + ' / ' + module.totalDependencies);
} else {
module.setStatus('Download complete');
module.setStatusDescription('');

4
src/Magnum/Platform/WindowlessEmscriptenApplication.js

@ -73,11 +73,11 @@ function createMagnumModule(init) {
totalDependencies: 0,
monitorRunDependencies: function(left) {
this.totalDependencies = Math.max(this.totalDependencies, left);
module.totalDependencies = Math.max(module.totalDependencies, left);
if(left) {
module.setStatus('Downloading...');
module.setStatusDescription((this.totalDependencies - left) + ' / ' + this.totalDependencies);
module.setStatusDescription((module.totalDependencies - left) + ' / ' + module.totalDependencies);
} else {
module.setStatus('Download complete');
module.setStatusDescription('');

Loading…
Cancel
Save