Fix issue with _super being removed from listeners

See https://github.com/CartoDB/cartodb.js/issues/478#issuecomment-102415466 for more details.
This commit is contained in:
Ilya Radchenko 2015-05-15 11:29:30 -04:00
parent 321258a891
commit 999b4d49f4

View File

@ -21,16 +21,17 @@ GMapsTileLoader.prototype = {
}, },
_removeTileLoader: function() { _removeTileLoader: function() {
for(var i in this._listeners) { this._listeners.forEach(function (listener) {
google.maps.event.removeListener(this._listeners[i]); google.maps.event.removeListener(listener);
} });
this._removeTiles(); this._removeTiles();
}, },
_removeTiles: function () { _removeTiles: function () {
for (var key in this._tiles) { for (var key in this._tiles) {
this._removeTile(key); this._removeTile(key);
} }
}, },
_reloadTiles: function() { _reloadTiles: function() {