Add ol.CollectionEvent#getElement

This commit is contained in:
Éric Lemoine
2013-08-27 22:07:03 +02:00
parent 9a994eab47
commit b9f2f7bcb4

View File

@@ -35,14 +35,23 @@ ol.CollectionEvent = function(type, opt_elem, opt_target) {
goog.base(this, type, opt_target);
/**
* @private
* @type {*}
*/
this.elem = opt_elem;
this.elem_ = opt_elem;
};
goog.inherits(ol.CollectionEvent, goog.events.Event);
/**
* @return {*} The element to which this event pertains.
*/
ol.CollectionEvent.prototype.getElement = function() {
return this.elem_;
};
/**
* @enum {string}
*/