Remove lint
This commit is contained in:
@@ -26,7 +26,7 @@ export function binarySearch(haystack, needle, opt_comparator) {
|
||||
cmp = +comparator(haystack[mid], needle);
|
||||
|
||||
if (cmp < 0.0) { /* Too low. */
|
||||
low = mid + 1;
|
||||
low = mid + 1;
|
||||
|
||||
} else { /* Key found or too high */
|
||||
high = mid;
|
||||
|
||||
@@ -25,7 +25,7 @@ export function clamp(value, min, max) {
|
||||
* @param {number} x X.
|
||||
* @return {number} Hyperbolic cosine of x.
|
||||
*/
|
||||
export const cosh = (function() {
|
||||
export const cosh = (function() {
|
||||
// Wrapped in a iife, to save the overhead of checking for the native
|
||||
// implementation on every invocation.
|
||||
let cosh;
|
||||
|
||||
@@ -660,7 +660,7 @@ class CanvasReplay extends VectorContext {
|
||||
case CanvasInstruction.DRAW_IMAGE:
|
||||
d = /** @type {number} */ (instruction[1]);
|
||||
dd = /** @type {number} */ (instruction[2]);
|
||||
image = /** @type {HTMLCanvasElement|HTMLVideoElement|HTMLImageElement} */
|
||||
image = /** @type {HTMLCanvasElement|HTMLVideoElement|HTMLImageElement} */
|
||||
(instruction[3]);
|
||||
// Remaining arguments in DRAW_IMAGE are in alphabetical order
|
||||
anchorX = /** @type {number} */ (instruction[4]);
|
||||
@@ -711,7 +711,7 @@ class CanvasReplay extends VectorContext {
|
||||
const measure = /** @type {function(string):number} */ (instruction[8]);
|
||||
const offsetY = /** @type {number} */ (instruction[9]);
|
||||
const strokeKey = /** @type {string} */ (instruction[10]);
|
||||
const strokeWidth = /** @type {number} */ (instruction[11]);
|
||||
const strokeWidth = /** @type {number} */ (instruction[11]);
|
||||
const text = /** @type {string} */ (instruction[12]);
|
||||
const textKey = /** @type {string} */ (instruction[13]);
|
||||
const textScale = /** @type {number} */ (instruction[14]);
|
||||
|
||||
@@ -266,7 +266,7 @@ class CanvasTextReplay extends CanvasReplay {
|
||||
const textState = this.textStates[textKey] || this.textState_;
|
||||
const pixelRatio = this.pixelRatio;
|
||||
const scale = textState.scale * pixelRatio;
|
||||
const align = TEXT_ALIGN[textState.textAlign || defaultTextAlign];
|
||||
const align = TEXT_ALIGN[textState.textAlign || defaultTextAlign];
|
||||
const strokeWidth = strokeKey && strokeState.lineWidth ? strokeState.lineWidth : 0;
|
||||
|
||||
const lines = text.split('\n');
|
||||
|
||||
@@ -136,7 +136,7 @@ class WebGLCircleReplay extends WebGLReplay {
|
||||
this.styles_.pop();
|
||||
if (this.styles_.length) {
|
||||
const lastState = this.styles_[this.styles_.length - 1];
|
||||
this.state_.fillColor = /** @type {Array.<number>} */ (lastState[0]);
|
||||
this.state_.fillColor = /** @type {Array.<number>} */ (lastState[0]);
|
||||
this.state_.strokeColor = /** @type {Array.<number>} */ (lastState[1]);
|
||||
this.state_.lineWidth = /** @type {number} */ (lastState[2]);
|
||||
this.state_.changed = false;
|
||||
|
||||
@@ -10,7 +10,7 @@ import EventType from '../events/EventType.js';
|
||||
import {FALSE, UNDEFINED} from '../functions.js';
|
||||
import SourceState from '../source/State.js';
|
||||
|
||||
class LayerRenderer extends Observable {
|
||||
class LayerRenderer extends Observable {
|
||||
|
||||
/**
|
||||
* @param {module:ol/layer/Layer} layer Layer.
|
||||
|
||||
@@ -132,7 +132,7 @@ class IntermediateCanvasRenderer extends CanvasLayerRenderer {
|
||||
|
||||
const imageData = this.hitCanvasContext_.getImageData(0, 0, 1, 1).data;
|
||||
if (imageData[3] > 0) {
|
||||
return callback.call(thisArg, this.getLayer(), imageData);
|
||||
return callback.call(thisArg, this.getLayer(), imageData);
|
||||
} else {
|
||||
return undefined;
|
||||
}
|
||||
|
||||
@@ -112,7 +112,7 @@ class CanvasVectorLayerRenderer extends CanvasLayerRenderer {
|
||||
const clipExtent = layerState.extent;
|
||||
const clipped = clipExtent !== undefined;
|
||||
if (clipped) {
|
||||
this.clip(context, frameState, /** @type {module:ol/extent~Extent} */ (clipExtent));
|
||||
this.clip(context, frameState, /** @type {module:ol/extent~Extent} */ (clipExtent));
|
||||
}
|
||||
const replayGroup = this.replayGroup_;
|
||||
if (replayGroup && !replayGroup.isEmpty()) {
|
||||
|
||||
@@ -266,7 +266,7 @@ class WebGLImageLayerRenderer extends WebGLLayerRenderer {
|
||||
|
||||
const imageData = this.hitCanvasContext_.getImageData(0, 0, 1, 1).data;
|
||||
if (imageData[3] > 0) {
|
||||
return callback.call(thisArg, this.getLayer(), imageData);
|
||||
return callback.call(thisArg, this.getLayer(), imageData);
|
||||
} else {
|
||||
return undefined;
|
||||
}
|
||||
|
||||
@@ -7,6 +7,6 @@
|
||||
* @enum {string}
|
||||
*/
|
||||
export default {
|
||||
KVP: 'KVP', // see spec §8
|
||||
KVP: 'KVP', // see spec §8
|
||||
REST: 'REST' // see spec §10
|
||||
};
|
||||
|
||||
@@ -246,7 +246,7 @@ class LRUCache extends EventTarget {
|
||||
* @param {T} value Value.
|
||||
*/
|
||||
replace(key, value) {
|
||||
this.get(key); // update `newest_`
|
||||
this.get(key); // update `newest_`
|
||||
this.entries_[key].value_ = value;
|
||||
}
|
||||
|
||||
|
||||
@@ -185,7 +185,7 @@ class RegularShape extends ImageStyle {
|
||||
radius2: this.getRadius2(),
|
||||
angle: this.getAngle(),
|
||||
snapToPixel: this.getSnapToPixel(),
|
||||
stroke: this.getStroke() ? this.getStroke().clone() : undefined,
|
||||
stroke: this.getStroke() ? this.getStroke().clone() : undefined,
|
||||
rotation: this.getRotation(),
|
||||
rotateWithView: this.getRotateWithView(),
|
||||
atlasManager: this.atlasManager_
|
||||
|
||||
Reference in New Issue
Block a user