destroy() should always come *right*after* initialize()
git-svn-id: http://svn.openlayers.org/trunk/openlayers@2930 dc9f47b5-9b13-0410-9fdd-eb0c1a62fdaf
This commit is contained in:
@@ -41,6 +41,19 @@ OpenLayers.Control.MouseToolbar.prototype =
|
||||
this.measureDivs = [];
|
||||
},
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
destroy: function() {
|
||||
for( var btnId in this.buttons) {
|
||||
var btn = this.buttons[btnId];
|
||||
btn.map = null;
|
||||
btn.events.destroy();
|
||||
}
|
||||
OpenLayers.Control.MouseDefaults.prototype.destroy.apply(this,
|
||||
arguments);
|
||||
},
|
||||
|
||||
draw: function() {
|
||||
OpenLayers.Control.prototype.draw.apply(this, arguments);
|
||||
OpenLayers.Control.MouseDefaults.prototype.draw.apply(this, arguments);
|
||||
@@ -58,19 +71,6 @@ OpenLayers.Control.MouseToolbar.prototype =
|
||||
return this.div;
|
||||
},
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
destroy: function() {
|
||||
for( var btnId in this.buttons) {
|
||||
var btn = this.buttons[btnId];
|
||||
btn.map = null;
|
||||
btn.events.destroy();
|
||||
}
|
||||
OpenLayers.Control.MouseDefaults.prototype.destroy.apply(this,
|
||||
arguments);
|
||||
},
|
||||
|
||||
_addButton:function(id, img, activeImg, xy, sz, title) {
|
||||
var imgLocation = OpenLayers.Util.getImagesLocation() + img;
|
||||
var activeImgLocation = OpenLayers.Util.getImagesLocation() + activeImg;
|
||||
|
||||
Reference in New Issue
Block a user