diff --git a/src/pixi/renderers/webgl/WebGLRenderer.js b/src/pixi/renderers/webgl/WebGLRenderer.js index 127b206..e333d78 100644 --- a/src/pixi/renderers/webgl/WebGLRenderer.js +++ b/src/pixi/renderers/webgl/WebGLRenderer.js @@ -99,11 +99,11 @@ this.view = options.view || document.createElement( 'canvas' ); // deal with losing context.. - this.contextLost = this.handleContextLost.bind(this); - this.contextRestoredLost = this.handleContextRestored.bind(this); + this.contextLostFunction = this.handleContextLost.bind(this); + this.contextRestoredFunction = this.handleContextRestored.bind(this); - this.view.addEventListener('webglcontextlost', this.contextLost, false); - this.view.addEventListener('webglcontextrestored', this.contextRestoredLost, false); + this.view.addEventListener('webglcontextlost', this.contextLostFunction, false); + this.view.addEventListener('webglcontextrestored', this.contextRestoredFunction, false); this.contextOptions = { alpha: this.transparent, @@ -581,8 +581,8 @@ // deal with losing context.. // remove listeners - this.view.removeEventListener('webglcontextlost', this.contextLost); - this.view.removeEventListener('webglcontextrestored', this.contextRestoredLost); + this.view.removeEventListener('webglcontextlost', this.contextLostFunction); + this.view.removeEventListener('webglcontextrestored', this.contextRestoredFunction); PIXI.glContexts[this.glContextId] = null;