[mapguide-commits] r4310 - trunk/MgDev/Common/Geometry/CoordinateSystem

svn_mapguide at osgeo.org svn_mapguide at osgeo.org
Tue Oct 20 01:46:06 EDT 2009


Author: leaf
Date: 2009-10-20 01:46:05 -0400 (Tue, 20 Oct 2009)
New Revision: 4310

Modified:
   trunk/MgDev/Common/Geometry/CoordinateSystem/CoordinateSystemGridSpecializationType.h
Log:
Fix unit test. Previously, constants in CoordinateSystemGrids.h aren't exposed by SWIG. Walt fixed it in two days ago. However, some of changes don't work for PHP. For example, class MgCoordinateSystemGridSpecializationType uses '()' when defining a constant. It doesn't follow PHP syntax. So it results in applications based on PHP API are broken. 

class MgCoordinateSystemGridSpecializationType
{
    ......
    static const INT32 Generic           = (0 + 1);
    ......
}

In this submission, I just remove '()' and use the computed value directly for those constants so that it follows PHP syntax.



Modified: trunk/MgDev/Common/Geometry/CoordinateSystem/CoordinateSystemGridSpecializationType.h
===================================================================
--- trunk/MgDev/Common/Geometry/CoordinateSystem/CoordinateSystemGridSpecializationType.h	2009-10-19 22:38:37 UTC (rev 4309)
+++ trunk/MgDev/Common/Geometry/CoordinateSystem/CoordinateSystemGridSpecializationType.h	2009-10-20 05:46:05 UTC (rev 4310)
@@ -39,17 +39,17 @@
     ///////////////////////////////////////////////////////////////////////////
     /// /brief Generic grid of a specified coordinate system; may be
     /// geographic or projected.
-    static const INT32 Generic           = (0 + 1);     // Generic grid of a specified coordinate system;
+    static const INT32 Generic           = 1;           // Generic grid of a specified coordinate system;
                                                         // may be geographic or projected
     ///////////////////////////////////////////////////////////////////////////
     /// /brief Specialized grid: MGRS (Military Grid Reference System)
-    static const INT32 MGRS              = (16 + 1);
+    static const INT32 MGRS              = 17;
     ///////////////////////////////////////////////////////////////////////////
     /// /brief Specialized grid: USNG (United States National Grid)
-    static const INT32 USNG              = (16 + 2);
+    static const INT32 USNG              = 18;
     ///////////////////////////////////////////////////////////////////////////
     /// /brief Indicates the failure of an algorithm or other problem.
-    static const INT32 Unknown           = (65366);
+    static const INT32 Unknown           = 65366;
 };
 
 #endif //_MGCOORDINATESYSTEMGRIDSPECIALIZATIONTYPE_H_



More information about the mapguide-commits mailing list