[fusion-commits] r2004 - trunk/layers/MapServer

svn_fusion at osgeo.org svn_fusion at osgeo.org
Wed Dec 2 13:36:11 EST 2009


Author: pdeschamps
Date: 2009-12-02 13:36:10 -0500 (Wed, 02 Dec 2009)
New Revision: 2004

Modified:
   trunk/layers/MapServer/MapServer.js
Log:
LayerManager layer reversal issue


Modified: trunk/layers/MapServer/MapServer.js
===================================================================
--- trunk/layers/MapServer/MapServer.js	2009-12-02 16:41:42 UTC (rev 2003)
+++ trunk/layers/MapServer/MapServer.js	2009-12-02 18:36:10 UTC (rev 2004)
@@ -3,7 +3,7 @@
  *
  * $Id$
  *
- * Copyright (c) 2007, DM Solutions Group Inc.nLayers
+ * Copyright (c) 2007, DM Solutions Group Inc.
  * Permission is hereby granted, free of charge, to any person obtaining a
  * copy of this software and associated documentation files (the "Software"),
  * to deal in the Software without restriction, including without limitation
@@ -456,31 +456,25 @@
     },
 
     mapLayersReset: function(aLayerIndex,r) {
+        //console.log("mapLayersReset");
         var o;
         eval('o='+r.responseText);
         if (o.success) {
             var layerCopy = $A(this.aLayers);
-            //console.dir(layerCopy);
             var nLayers = layerCopy.length -1;
-            //console.log("nLayers:"+nLayers);
-
             //Mapserver has list of layers reversed from MapGuide
-            //aLayerIndex.reverse();
+            aLayerIndex.reverse();
 
             this.aLayers = [];
             this.aVisibleLayers = [];
 
             for (var i=0; i<aLayerIndex.length; ++i) {
                 this.aLayers.push( layerCopy[aLayerIndex[i] ] );
-                //console.log("INDEX:"+(aLayerIndex[i]));
-                //console.log(layerCopy[aLayerIndex[i]].layerName);
                 if (this.aLayers[i].visible) {
                     this.aVisibleLayers.push(this.aLayers[i].layerName);
                 }
             }
-            //console.dir(this.aLayers);
             //this.layerRoot.clear();
-
             this.drawMap();
             this.triggerEvent(Fusion.Event.MAP_LAYER_ORDER_CHANGED);
         }



More information about the fusion-commits mailing list