Get rid of goog.functions

This commit is contained in:
Björn Harrtell
2016-03-20 19:39:00 +01:00
parent baf5287ad2
commit 44e04be67f
23 changed files with 91 additions and 56 deletions

View File

@@ -1,8 +1,8 @@
goog.provide('ol.renderer.canvas.ImageLayer');
goog.require('goog.asserts');
goog.require('goog.functions');
goog.require('goog.vec.Mat4');
goog.require('ol.functions');
goog.require('ol.ImageBase');
goog.require('ol.ViewHint');
goog.require('ol.dom');
@@ -87,7 +87,7 @@ ol.renderer.canvas.ImageLayer.prototype.forEachLayerAtPixel = function(pixel, fr
ol.vec.Mat4.multVec2(
frameState.pixelToCoordinateMatrix, coordinate, coordinate);
var hasFeature = this.forEachFeatureAtCoordinate(
coordinate, frameState, goog.functions.TRUE, this);
coordinate, frameState, ol.functions.TRUE, this);
if (hasFeature) {
return callback.call(thisArg, this.getLayer());

View File

@@ -3,8 +3,8 @@ goog.provide('ol.renderer.Layer');
goog.require('goog.asserts');
goog.require('ol.events');
goog.require('ol.events.EventType');
goog.require('goog.functions');
goog.require('ol');
goog.require('ol.functions');
goog.require('ol.ImageState');
goog.require('ol.Observable');
goog.require('ol.TileRange');
@@ -63,7 +63,7 @@ ol.renderer.Layer.prototype.forEachLayerAtPixel = function(pixel, frameState, ca
frameState.pixelToCoordinateMatrix, coordinate, coordinate);
var hasFeature = this.forEachFeatureAtCoordinate(
coordinate, frameState, goog.functions.TRUE, this);
coordinate, frameState, ol.functions.TRUE, this);
if (hasFeature) {
return callback.call(thisArg, this.layer_);
@@ -78,7 +78,7 @@ ol.renderer.Layer.prototype.forEachLayerAtPixel = function(pixel, frameState, ca
* @param {olx.FrameState} frameState Frame state.
* @return {boolean} Is there a feature at the given coordinate?
*/
ol.renderer.Layer.prototype.hasFeatureAtCoordinate = goog.functions.FALSE;
ol.renderer.Layer.prototype.hasFeatureAtCoordinate = ol.functions.FALSE;
/**

View File

@@ -2,13 +2,13 @@ goog.provide('ol.RendererType');
goog.provide('ol.renderer.Map');
goog.require('goog.asserts');
goog.require('goog.functions');
goog.require('goog.vec.Mat4');
goog.require('ol');
goog.require('ol.Disposable');
goog.require('ol.events');
goog.require('ol.events.EventType');
goog.require('ol.extent');
goog.require('ol.functions');
goog.require('ol.layer.Layer');
goog.require('ol.renderer.Layer');
goog.require('ol.style.IconImageCache');
@@ -232,7 +232,7 @@ ol.renderer.Map.prototype.forEachLayerAtPixel = function(pixel, frameState, call
*/
ol.renderer.Map.prototype.hasFeatureAtCoordinate = function(coordinate, frameState, layerFilter, thisArg) {
var hasFeature = this.forEachFeatureAtCoordinate(
coordinate, frameState, goog.functions.TRUE, this, layerFilter, thisArg);
coordinate, frameState, ol.functions.TRUE, this, layerFilter, thisArg);
return hasFeature !== undefined;
};

View File

@@ -1,7 +1,6 @@
goog.provide('ol.renderer.webgl.ImageLayer');
goog.require('goog.asserts');
goog.require('goog.functions');
goog.require('goog.vec.Mat4');
goog.require('goog.webgl');
goog.require('ol.Coordinate');
@@ -10,6 +9,7 @@ goog.require('ol.ImageBase');
goog.require('ol.ViewHint');
goog.require('ol.dom');
goog.require('ol.extent');
goog.require('ol.functions');
goog.require('ol.layer.Image');
goog.require('ol.proj');
goog.require('ol.renderer.webgl.Layer');
@@ -221,7 +221,7 @@ ol.renderer.webgl.ImageLayer.prototype.updateProjectionMatrix_ = function(canvas
*/
ol.renderer.webgl.ImageLayer.prototype.hasFeatureAtCoordinate = function(coordinate, frameState) {
var hasFeature = this.forEachFeatureAtCoordinate(
coordinate, frameState, goog.functions.TRUE, this);
coordinate, frameState, ol.functions.TRUE, this);
return hasFeature !== undefined;
};
@@ -241,7 +241,7 @@ ol.renderer.webgl.ImageLayer.prototype.forEachLayerAtPixel = function(pixel, fra
ol.vec.Mat4.multVec2(
frameState.pixelToCoordinateMatrix, coordinate, coordinate);
var hasFeature = this.forEachFeatureAtCoordinate(
coordinate, frameState, goog.functions.TRUE, this);
coordinate, frameState, ol.functions.TRUE, this);
if (hasFeature) {
return callback.call(thisArg, this.getLayer());