From 199fcb05e3fc643bc95a050b3b318285f460b494 Mon Sep 17 00:00:00 2001 From: Tim Schaub Date: Tue, 17 Feb 2015 11:20:11 -0700 Subject: [PATCH] Unregister image listeners when disposing of a tile --- src/ol/imagetile.js | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/ol/imagetile.js b/src/ol/imagetile.js index d62f5516a2..4deb7bd362 100644 --- a/src/ol/imagetile.js +++ b/src/ol/imagetile.js @@ -64,6 +64,15 @@ ol.ImageTile = function(tileCoord, state, src, crossOrigin, tileLoadFunction) { goog.inherits(ol.ImageTile, ol.Tile); +/** + * @inheritDoc + */ +ol.ImageTile.prototype.disposeInternal = function() { + this.unlistenImage_(); + goog.base(this, 'disposeInternal'); +}; + + /** * @inheritDoc * @api