[Users] internet explorer extremely slow with spatial filter

Simone Dalmasso simone.dalmasso at gmail.com
Tue Nov 23 11:21:57 CET 2010


Hi, I need to have my map to show features if they are in the current extent
and if they match a selected category.
So I've written a filter function that uses the filterBy of the
FeatureStore:

*function sitesFilter(){*
* **var extent = map.getExtent();*
* **featureStore.filterBy(function(record){*
* **var currentCategory = Ext.getCmp('category').value;*
* **var feature = record.data.feature;*
* **if(feature.data.category == currentCategory){*
* **return extent.containsLonLat(new
OpenLayers.LonLat(feature.geometry.x,feature.geometry.y));*
* **}else if(!currentCategory || currentCategory == 'ALL'){*
* **return extent.containsLonLat(new
OpenLayers.LonLat(feature.geometry.x,feature.geometry.y));*
* **}*
* **});*

this is called on zoomend, moveend or when a category is chosen.
All works pretty well and quick with each browser except for ie which is
extremely slow and unusable.

Is there something I can do to speed it up?

Thanks in advance
-- 
Simone
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.geoext.org/pipermail/users/attachments/20101123/42d6129d/attachment.htm 


More information about the Users mailing list