Declare 'proj' and 'projCode' properties, simplify verbose code

git-svn-id: http://svn.openlayers.org/trunk/openlayers@5408 dc9f47b5-9b13-0410-9fdd-eb0c1a62fdaf
This commit is contained in:
Frédéric Junod
2007-12-14 13:52:43 +00:00
parent c1eb0fe24b
commit 9dd5d0e6da

View File

@@ -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