set a default EPSG:4326 externalProjection to the KML, OSM and GPX formats. r=pgiraud (closes #2424)

git-svn-id: http://svn.openlayers.org/trunk/openlayers@9975 dc9f47b5-9b13-0410-9fdd-eb0c1a62fdaf
This commit is contained in:
Frédéric Junod
2010-01-27 14:36:46 +00:00
parent c1f9945838
commit e5aab2453d
6 changed files with 21 additions and 3 deletions
+4
View File
@@ -11,6 +11,7 @@
* @requires OpenLayers/Geometry/Collection.js
* @requires OpenLayers/Request/XMLHttpRequest.js
* @requires OpenLayers/Console.js
* @requires OpenLayers/Projection.js
*/
/**
@@ -122,6 +123,9 @@ OpenLayers.Format.KML = OpenLayers.Class(OpenLayers.Format.XML, {
kmlIconPalette: (/root:\/\/icons\/palette-(\d+)(\.\w+)/),
straightBracket: (/\$\[(.*?)\]/g)
};
// KML coordinates are always in longlat WGS84
this.externalProjection = new OpenLayers.Projection("EPSG:4326");
OpenLayers.Format.XML.prototype.initialize.apply(this, [options]);
},