Allow click events on Marker elements to fall through if they are not handled.

This commit is contained in:
danzel 2012-10-04 10:13:30 +13:00
parent 53f57cb45f
commit f435217301

View File

@ -187,7 +187,9 @@ L.Marker = L.Class.extend({
}, },
_onMouseClick: function (e) { _onMouseClick: function (e) {
if (this.hasEventListeners(e.type)) {
L.DomEvent.stopPropagation(e); L.DomEvent.stopPropagation(e);
}
if (this.dragging && this.dragging.moved()) { return; } if (this.dragging && this.dragging.moved()) { return; }
if (this._map.dragging && this._map.dragging.moved()) { return; } if (this._map.dragging && this._map.dragging.moved()) { return; }
this.fire(e.type, { this.fire(e.type, {