do not specify the source projection in ol.parser.ReadFeaturesOptions anymore
This commit is contained in:
@@ -41,7 +41,7 @@ var map = new ol.Map({
|
||||
})
|
||||
});
|
||||
|
||||
var gml = new ol.parser.ogc.GML_v3();
|
||||
var gml = new ol.parser.ogc.GML_v3({axisOrientation: 'neu'});
|
||||
|
||||
var url = 'data/gml/topp-states-wfs.xml';
|
||||
var xhr = new XMLHttpRequest();
|
||||
|
||||
@@ -349,8 +349,7 @@ ol.layer.Vector.prototype.parseFeatures = function(data, parser, projection) {
|
||||
this.addFeatures(features);
|
||||
};
|
||||
|
||||
var options = {callback: callback, projection:
|
||||
this.getSource().getProjection()};
|
||||
var options = {callback: callback};
|
||||
if (goog.isString(data)) {
|
||||
if (goog.isFunction(parser.readFeaturesFromStringAsync)) {
|
||||
parser.readFeaturesFromStringAsync(data, goog.bind(addFeatures, this),
|
||||
|
||||
@@ -97,7 +97,6 @@ ol.parser.ReadFeaturesCallback;
|
||||
|
||||
|
||||
/**
|
||||
* @typedef {{callback: ol.parser.ReadFeaturesCallback,
|
||||
* projection: ol.Projection}}
|
||||
* @typedef {{callback: ol.parser.ReadFeaturesCallback}}
|
||||
*/
|
||||
ol.parser.ReadFeaturesOptions;
|
||||
|
||||
@@ -552,8 +552,5 @@ ol.parser.ogc.GML.prototype.createGeometry_ = function(container,
|
||||
ol.parser.ogc.GML.prototype.readFeaturesFromString =
|
||||
function(str, opt_options) {
|
||||
this.readFeaturesOptions_ = opt_options;
|
||||
if (goog.isDef(opt_options) && goog.isDef(opt_options.projection)) {
|
||||
this.axisOrientation = opt_options.projection.getAxisOrientation();
|
||||
}
|
||||
return this.read(str).features;
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user