drag marker can no longer be removed by clicking on it

This commit is contained in:
DennisSchiefer 2012-04-05 09:04:48 +02:00
parent 0f032f7635
commit f273f0cfc5

View File

@ -141,7 +141,8 @@ OSRM.DragMarker = function ( label, style, position ) {
OSRM.inheritFrom( OSRM.DragMarker, OSRM.RouteMarker );
OSRM.extend( OSRM.DragMarker, {
onClick: function(e) {
this.parent.hide();
if( this.parent != OSRM.G.markers.dragger)
this.parent.hide();
},
onDragStart: function(e) {
var new_via_index = OSRM.Via.findViaIndex( e.target.getLatLng() );