From 6c7f50a38e2298f8f82c2aff7bbcf6394a31ba6c Mon Sep 17 00:00:00 2001 From: Frederic Junod Date: Mon, 5 Sep 2016 09:11:01 +0200 Subject: [PATCH 1/4] Add '=' to optional parameter annotation --- src/ol/interaction/extent.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/ol/interaction/extent.js b/src/ol/interaction/extent.js index fb6b1a6e6d..1e414d9fc4 100644 --- a/src/ol/interaction/extent.js +++ b/src/ol/interaction/extent.js @@ -61,7 +61,7 @@ ol.inherits(ol.interaction.ExtentEvent, ol.events.Event); * @constructor * @extends {ol.interaction.Pointer} * @fires ol.interaction.ExtentEvent - * @param {olx.interaction.ExtentOptions} opt_options Options. + * @param {olx.interaction.ExtentOptions=} opt_options Options. * @api */ ol.interaction.Extent = function(opt_options) { From d863cff28d84acb09acfdceca8c05875a9447aa6 Mon Sep 17 00:00:00 2001 From: Frederic Junod Date: Mon, 5 Sep 2016 09:12:06 +0200 Subject: [PATCH 2/4] Remove unused lastPixel_ in ol.interaction.Extent --- src/ol/interaction/extent.js | 8 -------- 1 file changed, 8 deletions(-) diff --git a/src/ol/interaction/extent.js b/src/ol/interaction/extent.js index 1e414d9fc4..fc25d9e051 100644 --- a/src/ol/interaction/extent.js +++ b/src/ol/interaction/extent.js @@ -87,13 +87,6 @@ ol.interaction.Extent = function(opt_options) { */ this.pixelTolerance_ = 10; - /** - * Last known pixel coordinate of the pointer - * @type {ol.Pixel} - * @private - */ - this.lastPixel_ = null; - /** * Is the pointer snapped to an extent vertex * @type {boolean} @@ -251,7 +244,6 @@ ol.interaction.Extent.handleDownEvent_ = function(mapBrowserEvent) { * @private */ ol.interaction.Extent.handleDragEvent_ = function(mapBrowserEvent) { - this.lastPixel_ = mapBrowserEvent.pixel; if (this.pointerHandler_) { var pixelCoordinate = mapBrowserEvent.coordinate; this.setExtent(this.pointerHandler_(pixelCoordinate)); From cd7bc2e4bf9bffa047184e3cbe3c6fdadecc08e2 Mon Sep 17 00:00:00 2001 From: Frederic Junod Date: Mon, 5 Sep 2016 09:12:57 +0200 Subject: [PATCH 3/4] Remove unused removeExtentFeature_ function in ol.interaction.Extent --- src/ol/interaction/extent.js | 11 ----------- 1 file changed, 11 deletions(-) diff --git a/src/ol/interaction/extent.js b/src/ol/interaction/extent.js index fc25d9e051..6c7fb2efad 100644 --- a/src/ol/interaction/extent.js +++ b/src/ol/interaction/extent.js @@ -424,17 +424,6 @@ ol.interaction.Extent.prototype.createOrUpdateExtentFeature_ = function(extent) return extentFeature; }; -/** - * @this {ol.interaction.Extent} - * @private - */ -ol.interaction.Extent.prototype.removeExtentFeature_ = function() { - var extentFeature = this.extentFeature_; - if (extentFeature) { - this.extentOverlay_.getSource().removeFeature(extentFeature); - this.extentFeature_ = null; - } -}; /** * @param {ol.Coordinate} vertex location of feature From ed4401e15e769d8ee6f9583c6fae22e43671e455 Mon Sep 17 00:00:00 2001 From: Frederic Junod Date: Mon, 5 Sep 2016 09:14:25 +0200 Subject: [PATCH 4/4] Remove unused removeExtentFeature_ function in ol.interaction.Extent --- src/ol/interaction/extent.js | 10 ---------- 1 file changed, 10 deletions(-) diff --git a/src/ol/interaction/extent.js b/src/ol/interaction/extent.js index 6c7fb2efad..ddf6f0526f 100644 --- a/src/ol/interaction/extent.js +++ b/src/ol/interaction/extent.js @@ -443,16 +443,6 @@ ol.interaction.Extent.prototype.createOrUpdatePointerFeature_ = function(vertex) return vertexFeature; }; -/** - * @private - */ -ol.interaction.Extent.prototype.removePointerFeature_ = function() { - var vertexFeature = this.vertexFeature_; - if (vertexFeature) { - this.vertexOverlay_.getSource().removeFeature(vertexFeature); - this.vertexFeature_ = null; - } -}; /** * @inheritDoc