ghost features stay displayed with select feature control, r=pgiraud (closes #1865)

git-svn-id: http://svn.openlayers.org/trunk/openlayers@8899 dc9f47b5-9b13-0410-9fdd-eb0c1a62fdaf
This commit is contained in:
Éric Lemoine
2009-02-26 15:19:43 +00:00
parent 218ab8c9c6
commit f04f203499

View File

@@ -277,7 +277,7 @@ OpenLayers.Control.ModifyFeature = OpenLayers.Class(OpenLayers.Control, {
this.layer.removeFeatures(this.virtualVertices, {silent: true});
this.vertices = [];
this.dragControl.deactivate();
if(this.feature && this.feature.geometry) {
if(this.feature && this.feature.geometry && this.feature.layer) {
this.selectControl.unselect.apply(this.selectControl,
[this.feature]);
}