diff --git a/externs/oli.js b/externs/oli.js index 731886a2d8..9e4d5632fe 100644 --- a/externs/oli.js +++ b/externs/oli.js @@ -18,6 +18,16 @@ oli.CollectionEvent = function() {}; oli.CollectionEvent.prototype.element; + +/** @interface */ +oli.DragBoxEvent; + + +/** @type {ol.Coordinate} */ +oli.DragBoxEvent.prototype.coordinate; + + + /** @interface */ oli.DrawEvent; diff --git a/src/ol/interaction/dragboxinteraction.exports b/src/ol/interaction/dragboxinteraction.exports index 7553395958..7b578e067a 100644 --- a/src/ol/interaction/dragboxinteraction.exports +++ b/src/ol/interaction/dragboxinteraction.exports @@ -1,4 +1,2 @@ @exportSymbol ol.interaction.DragBox @exportProperty ol.interaction.DragBox.prototype.getGeometry - -@exportProperty ol.DragBoxEvent.prototype.getCoordinate diff --git a/src/ol/interaction/dragboxinteraction.js b/src/ol/interaction/dragboxinteraction.js index 44cdf04267..f12f1c2f7c 100644 --- a/src/ol/interaction/dragboxinteraction.js +++ b/src/ol/interaction/dragboxinteraction.js @@ -44,30 +44,22 @@ ol.DragBoxEventType = { * @param {ol.Coordinate} coordinate The event coordinate. * @extends {goog.events.Event} * @constructor + * @implements {oli.DragBoxEvent} */ ol.DragBoxEvent = function(type, coordinate) { goog.base(this, type); /** * The coordinate of the drag event. + * @const * @type {ol.Coordinate} - * @private */ - this.coordinate_ = coordinate; + this.coordinate = coordinate; }; goog.inherits(ol.DragBoxEvent, goog.events.Event); -/** - * Get the name of the property associated with this event. - * @return {ol.Coordinate} Event coordinate. - */ -ol.DragBoxEvent.prototype.getCoordinate = function() { - return this.coordinate_; -}; - - /** * @constructor