<html><head></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">Hey,<div><br></div><div>our API docs for Map state that projection is always a string, but it can also be a Projection object [1].</div><div><br></div><div><div>&nbsp; &nbsp; /**</div><div>&nbsp; &nbsp; &nbsp;* APIProperty: projection</div><div>&nbsp; &nbsp; &nbsp;* {String} Set in the map options to override the default projection&nbsp;</div><div>&nbsp; &nbsp; &nbsp;* &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;string this map. When using a projection other than EPSG:4326</div><div>&nbsp; &nbsp; &nbsp;* &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;(CRS:84, Geographic) or EPSG:3857 (EPSG:900913, Web Mercator),</div><div>&nbsp; &nbsp; &nbsp;* &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;also set maxExtent and maxResolution. &nbsp;Default is "EPSG:4326".</div><div>&nbsp; &nbsp; &nbsp;*/</div><div>&nbsp; &nbsp; projection: "EPSG:4326",</div></div><div><br></div><div>So there are several options to fix this:</div><div><br></div><div>A) make projection just a property, and not an API property, and have people use getProjection or getProjectionObject API methods instead</div><div>B) update the API docs for projection stating that it can be a string or an OpenLayers.Projection object.</div><div><br></div><div>Thoughts?</div><div><br></div><div>[1]</div><div><div>&nbsp; &nbsp; &nbsp; &nbsp; var projCode = this.projection instanceof OpenLayers.Projection ?</div><div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; this.projection.projCode : this.projection;</div></div><div><br></div><div>Best regards,</div><div>Bart</div><div><br></div><div><div apple-content-edited="true">
<div>--&nbsp;<br>Bart van den Eijnden<br>OpenGeo -&nbsp;<a href="http://opengeo.org/">http://opengeo.org</a><br>Expert service straight from the developers.</div><div><br></div><br class="Apple-interchange-newline">
</div>
<br></div></body></html>