Merge pull request #1033 from danzel/fix-events
Allow click events to propogate through
This commit is contained in:
commit
85d350e322
@ -187,7 +187,9 @@ L.Marker = L.Class.extend({
|
|||||||
},
|
},
|
||||||
|
|
||||||
_onMouseClick: function (e) {
|
_onMouseClick: function (e) {
|
||||||
L.DomEvent.stopPropagation(e);
|
if (this.hasEventListeners(e.type)) {
|
||||||
|
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, {
|
||||||
|
@ -113,7 +113,9 @@ L.Path = L.Path.extend({
|
|||||||
|
|
||||||
this._fireMouseEvent(e);
|
this._fireMouseEvent(e);
|
||||||
|
|
||||||
L.DomEvent.stopPropagation(e);
|
if (this.hasEventListeners(e.type)) {
|
||||||
|
L.DomEvent.stopPropagation(e);
|
||||||
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
_fireMouseEvent: function (e) {
|
_fireMouseEvent: function (e) {
|
||||||
|
Loading…
Reference in New Issue
Block a user