Changeset 7485
- Timestamp:
- 07/09/08 11:44:06 (2 months ago)
- Files:
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
sandbox/vector-behavior/lib/OpenLayers/Layer/Vector.js
r7484 r7485 235 235 */ 236 236 destroy: function() { 237 if (this.stategies) { 238 for(var i = 0; i < this.strategies.length; i++){ 239 this.strategies[i].destroy(); 240 this.strategies[i] = null; 241 } 242 this.strategies = null; 243 } 244 if (this.strategy) { 245 this.strategy.destroy(); 246 this.strategy = null; 247 } 248 if (this.protocol) { 249 this.protocol.destroy(); 250 this.protocol = null; 251 } 237 252 this.destroyFeatures(); 238 253 this.features = null; … … 245 260 this.geometryType = null; 246 261 this.drawn = null; 247 248 if (this.protocol) {249 this.protocol.destroy();250 this.protocol = null;251 }252 if (this.stategies) {253 for(var i = 0; i < this.strategies.length; i++){254 this.strategies[i].destroy();255 this.strategies[i] = null;256 }257 this.strategies = null;258 }259 if (this.strategy) {260 this.strategy.destroy();261 this.strategy = null;262 }263 262 OpenLayers.Layer.prototype.destroy.apply(this, arguments); 264 263 },
