[fusion-users] Updating (refreshing) just 1 layer.

cremebrulee iowa747 at gmail.com
Sun Apr 28 08:04:18 PDT 2013


I am using MapGuide Open Source 2.2 /  fusion client viewer running on RedHat
Enterprise Linux 5. 
I am updating feature sources, utilizing the Java web API, and updating the
concerned attribute values in my sdf files. In order for this updated sdf
data to be reflected in the client viewer i do a map redraw which refreshes
the map (mainting current zoom etc) however there seems to be a flicker.  I
would instead like the viewer to update just one layer (the layer that has
that particular updated sdf file). However I am not able to do so and have
included a snippet my javascript code. Any ideas of how i can achieve this?

var map = Fusion.getWidgetById('Map');
*//map.redraw(); this is what i was using to to the complete map refresh*
var mapWidget = Fusion.getWidgetById("Map").aMaps[0];
var layers = mapWidget.aLayers;
for (var i=0; i<layers.length; i++)
    {        
      var layer = layers[i];
        if (layer.layerName == 'alarms')
        {
                 <i>*//layer.redraw();
                 layer.refresh(); //I have tried this two funtions calls and
neither work*/
        }
    } 



-----
-MGnoob
--
View this message in context: http://osgeo-org.1560.x6.nabble.com/Updating-refreshing-just-1-layer-tp5050063.html
Sent from the Fusion Users mailing list archive at Nabble.com.


More information about the fusion-users mailing list