[fusion-commits] r2075 - in sandbox/adsk/2.2gp: layers/MapGuide lib

svn_fusion at osgeo.org svn_fusion at osgeo.org
Wed Feb 17 13:44:38 EST 2010


Author: madair
Date: 2010-02-17 13:44:38 -0500 (Wed, 17 Feb 2010)
New Revision: 2075

Modified:
   sandbox/adsk/2.2gp/layers/MapGuide/MapGuide.js
   sandbox/adsk/2.2gp/lib/Map.js
Log:
re #315: copy over the EPSG code in MapGuide if it is available

Modified: sandbox/adsk/2.2gp/layers/MapGuide/MapGuide.js
===================================================================
--- sandbox/adsk/2.2gp/layers/MapGuide/MapGuide.js	2010-02-17 18:43:58 UTC (rev 2074)
+++ sandbox/adsk/2.2gp/layers/MapGuide/MapGuide.js	2010-02-17 18:44:38 UTC (rev 2075)
@@ -303,6 +303,9 @@
             }
 
             //set projection units and code if supplied
+            if (o.epsg != 0) {
+              this.projCode = "EPSG:" + o.epsg;
+            }
             //TODO: consider passing the metersPerUnit value into the framework
             //to allow for scaling that doesn't match any of the pre-canned units
             this.units = Fusion.getClosestUnits(o.metersPerUnit);

Modified: sandbox/adsk/2.2gp/lib/Map.js
===================================================================
--- sandbox/adsk/2.2gp/lib/Map.js	2010-02-17 18:43:58 UTC (rev 2074)
+++ sandbox/adsk/2.2gp/lib/Map.js	2010-02-17 18:44:38 UTC (rev 2075)
@@ -811,10 +811,6 @@
      * @param projCode projection code
      */
     setProjection: function(projCode, units) {
-        if (!Proj4js.defs[projCode]) {
-          Fusion.reportError( new Fusion.Error(Fusion.Error.WARNING,
-            'Projection definition not found for:'+projCode));
-        }
         this.projection = projCode;
         this.oMapOL.projection = projCode;
         this.oMapOL.units = units;



More information about the fusion-commits mailing list