[OpenLayers-Users] listener function on event "loadend" runs	twice
    Steffen G 
    martsystems at gmx.net
       
    Wed Jan  8 02:56:58 PST 2014
    
    
  
Hi,
got the same problem. 
Overwriting the triggerRead() method solve it.
OpenLayers.Strategy.BBOX.prototype.triggerRead = function(options) {
/*
    if (this.response) { // in my option not correct mybe
this.response.error
       this.layer.protocol.abort(this.response);
       this.layer.events.triggerEvent("loadend"); // raise without error
    }*/
    this.layer.events.triggerEvent("loadstart");
    this.response = this.layer.protocol.read(
        OpenLayers.Util.applyDefaults({
            filter: this.createFilter(),
            callback: this.merge,
            scope: this
    }, options));
};
--
View this message in context: http://osgeo-org.1560.x6.nabble.com/listener-function-on-event-loadend-runs-twice-tp3912631p5096934.html
Sent from the OpenLayers Users mailing list archive at Nabble.com.
    
    
More information about the Users
mailing list