Introduce defaultDataProjection for formats

This commit is contained in:
tsauerwein
2014-08-18 14:28:43 +02:00
parent 1205d0fe1e
commit 539e4a23b9
17 changed files with 145 additions and 91 deletions

View File

@@ -26,6 +26,11 @@ goog.require('ol.xml');
*/
ol.format.OSMXML = function() {
goog.base(this);
/**
* @inheritDoc
*/
this.defaultDataProjection = ol.proj.get('EPSG:4326');
};
goog.inherits(ol.format.OSMXML, ol.format.XMLFeature);
@@ -231,7 +236,7 @@ ol.format.OSMXML.prototype.readProjection;
* @inheritDoc
*/
ol.format.OSMXML.prototype.readProjectionFromDocument = function(doc) {
return ol.proj.get('EPSG:4326');
return this.defaultDataProjection;
};
@@ -239,5 +244,5 @@ ol.format.OSMXML.prototype.readProjectionFromDocument = function(doc) {
* @inheritDoc
*/
ol.format.OSMXML.prototype.readProjectionFromNode = function(node) {
return ol.proj.get('EPSG:4326');
return this.defaultDataProjection;
};