Put options on objectStack for xml formats

This commit is contained in:
tsauerwein
2014-08-19 09:42:44 +02:00
parent e7864be2be
commit b30ed6b934
12 changed files with 90 additions and 95 deletions

View File

@@ -314,9 +314,10 @@ ol.format.Polyline.prototype.readGeometryFromText =
var coordinates = ol.geom.flat.inflate.coordinates(
flatCoordinates, 0, flatCoordinates.length, 2);
return ol.format.Feature.transformWithOptions(
new ol.geom.LineString(coordinates), false, false,
this.adaptOptionsWithDefaultDataProjection(opt_options));
return /** @type {ol.geom.Geometry} */ (
ol.format.Feature.transformWithOptions(
new ol.geom.LineString(coordinates), false,
this.adaptOptionsWithDefaultDataProjection(opt_options)));
};
@@ -383,7 +384,7 @@ ol.format.Polyline.prototype.writeGeometryText =
goog.asserts.assertInstanceof(geometry, ol.geom.LineString);
geometry = /** @type {ol.geom.LineString} */
(ol.format.Feature.transformWithOptions(
geometry, true, true,
geometry, true,
this.adaptOptionsWithDefaultDataProjection(opt_options)));
var flatCoordinates = geometry.getFlatCoordinates();
var stride = geometry.getStride();