Add ol.format.KML.SCHEMA_LOCATION_

This commit is contained in:
Éric Lemoine
2014-06-26 15:12:12 +02:00
parent 02b8ef1bb6
commit 177188d732
+4 -6
View File
@@ -165,13 +165,11 @@ ol.format.KML.NAMESPACE_URIS_ = [
/** /**
* @const * @const
* @type {Array.<string>} * @type {string}
* @private * @private
*/ */
ol.format.KML.XSD_URIS_ = [ ol.format.KML.SCHEMA_LOCATION_ = 'http://www.opengis.net/kml/2.2 ' +
'http://www.opengis.net/kml/2.2', 'https://developers.google.com/kml/schema/kml22gx.xsd';
'https://developers.google.com/kml/schema/kml22gx.xsd'
];
/** /**
@@ -2534,7 +2532,7 @@ ol.format.KML.prototype.writeFeaturesNode = function(features) {
ol.format.KML.GX_NAMESPACE_URIS_[0]); ol.format.KML.GX_NAMESPACE_URIS_[0]);
ol.xml.setAttributeNS(kml, xmlnsUri, 'xmlns:xsi', xmlSchemaInstanceUri); ol.xml.setAttributeNS(kml, xmlnsUri, 'xmlns:xsi', xmlSchemaInstanceUri);
ol.xml.setAttributeNS(kml, xmlSchemaInstanceUri, 'xsi:schemaLocation', ol.xml.setAttributeNS(kml, xmlSchemaInstanceUri, 'xsi:schemaLocation',
ol.format.KML.XSD_URIS_.join(' ')); ol.format.KML.SCHEMA_LOCATION_);
var /** @type {ol.xml.NodeStackItem} */ context = {node: kml}; var /** @type {ol.xml.NodeStackItem} */ context = {node: kml};
var properties = {}; var properties = {};