Permalink gets a destroy method. Fixes #594.
git-svn-id: http://svn.openlayers.org/trunk/openlayers@2935 dc9f47b5-9b13-0410-9fdd-eb0c1a62fdaf
This commit is contained in:
@@ -32,6 +32,20 @@ OpenLayers.Control.Permalink.prototype =
|
||||
}
|
||||
},
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
destroy: function() {
|
||||
if (this.element.parentNode == this.div) {
|
||||
this.div.removeChild(this.element);
|
||||
}
|
||||
this.element = null;
|
||||
|
||||
this.map.events.unregister('moveend', this, this.updateLink);
|
||||
|
||||
OpenLayers.Control.prototype.destroy.apply(this, arguments);
|
||||
},
|
||||
|
||||
/** Set the map property for the control.
|
||||
*
|
||||
* @param {OpenLayers.Map} map
|
||||
|
||||
Reference in New Issue
Block a user