Implement ol.renderer.Layer#forEachFeatureAtCoordinate
And remove identical implementation in children classes.
This commit is contained in:
@@ -71,29 +71,6 @@ ol.renderer.webgl.ImageLayer.prototype.createTexture_ = function(image) {
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* @inheritDoc
|
||||
*/
|
||||
ol.renderer.webgl.ImageLayer.prototype.forEachFeatureAtCoordinate =
|
||||
function(coordinate, frameState, callback, thisArg) {
|
||||
var layer = this.getLayer();
|
||||
var source = layer.getSource();
|
||||
var resolution = frameState.viewState.resolution;
|
||||
var rotation = frameState.viewState.rotation;
|
||||
var skippedFeatureUids = frameState.skippedFeatureUids;
|
||||
return source.forEachFeatureAtCoordinate(
|
||||
coordinate, resolution, rotation, skippedFeatureUids,
|
||||
|
||||
/**
|
||||
* @param {ol.Feature} feature Feature.
|
||||
* @return {?} Callback result.
|
||||
*/
|
||||
function(feature) {
|
||||
return callback.call(thisArg, feature, layer);
|
||||
});
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* @inheritDoc
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user