From 9dd5d0e6dada538efb1092084fa9093138df2230 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fr=C3=A9d=C3=A9ric=20Junod?= Date: Fri, 14 Dec 2007 13:52:43 +0000 Subject: [PATCH] Declare 'proj' and 'projCode' properties, simplify verbose code git-svn-id: http://svn.openlayers.org/trunk/openlayers@5408 dc9f47b5-9b13-0410-9fdd-eb0c1a62fdaf --- lib/OpenLayers/Projection.js | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) diff --git a/lib/OpenLayers/Projection.js b/lib/OpenLayers/Projection.js index 750970735a..53cbae45b8 100644 --- a/lib/OpenLayers/Projection.js +++ b/lib/OpenLayers/Projection.js @@ -11,7 +11,19 @@ * then this is just an empty stub. */ OpenLayers.Projection = OpenLayers.Class({ + + /** + * Property: proj + * {Object} Proj4js.Proj instance. + */ + proj: null, + /** + * Property: projCode + * {String} + */ + projCode: null, + /** * Constructor: OpenLayers.Projection * This class offers several methods for interacting with a wrapped @@ -75,10 +87,7 @@ OpenLayers.Projection = OpenLayers.Class({ * {Boolean} The two projections are equivalent. */ equals: function(projection) { - if (this.getCode() == projection.getCode()) { - return true; - } - return false; + return this.getCode() == projection.getCode(); }, /* Method: destroy