]> git.saurik.com Git - wxWidgets.git/blobdiff - include/wx/xrc/xmlres.h
Don't define __STRICT_ANSI__, we should build both with and without it.
[wxWidgets.git] / include / wx / xrc / xmlres.h
index 23cbea1c518e9decce971d756b5981c06d3921e5..f69d9939d957f3928cd8ffbe64432ce9c53007af 100644 (file)
@@ -3,7 +3,6 @@
 // Purpose:     XML resources
 // Author:      Vaclav Slavik
 // Created:     2000/03/05
-// RCS-ID:      $Id$
 // Copyright:   (c) 2000 Vaclav Slavik
 // Licence:     wxWindows licence
 /////////////////////////////////////////////////////////////////////////////
@@ -261,8 +260,16 @@ public:
     // Compares resources version to argument. Returns -1 if resources version
     // is less than the argument, +1 if greater and 0 if they equal.
     int CompareVersion(int major, int minor, int release, int revision) const
-        { return GetVersion() -
-                 (major*256*256*256 + minor*256*256 + release*256 + revision); }
+    {
+        long diff = GetVersion() -
+                    (major*256*256*256 + minor*256*256 + release*256 + revision);
+        if ( diff < 0 )
+            return -1;
+        else if ( diff > 0 )
+            return +1;
+        else
+            return 0;
+    }
 
     //// Singleton accessors.