Clear the feature stored by the DragFeature control when the user moves the mouse out or when dragging completes (closes #942).
git-svn-id: http://svn.openlayers.org/trunk/openlayers@4111 dc9f47b5-9b13-0410-9fdd-eb0c1a62fdaf
This commit is contained in:
@@ -237,6 +237,7 @@ OpenLayers.Control.DragFeature = OpenLayers.Class(OpenLayers.Control, {
|
||||
*/
|
||||
doneDragging: function(pixel) {
|
||||
this.onComplete(this.feature, pixel);
|
||||
this.feature = null;
|
||||
},
|
||||
|
||||
/**
|
||||
@@ -252,6 +253,7 @@ OpenLayers.Control.DragFeature = OpenLayers.Class(OpenLayers.Control, {
|
||||
this.dragHandler.deactivate();
|
||||
// TBD replace with CSS classes
|
||||
this.map.div.style.cursor = "default";
|
||||
this.feature = null;
|
||||
} else {
|
||||
if(this.feature.id == feature.id) {
|
||||
this.over = false;
|
||||
|
||||
Reference in New Issue
Block a user