             if (mapObject is GeoBaseEntityPointAnnotation){
                 mapView.removeAnnotation(mapObject as MKAnnotation);
             }
-            else if (mapObject is MKPolyline){
-                mapView.removeOverlay(mapObject as MKOverlay);
+            else if (mapObject is GeoBaseEntityStyledMkPolylineAnnotation){
+                mapView.removeOverlay(mapObject as GeoBaseEntityStyledMkPolylineAnnotation);
             }
         }
     }

               // mapView.showAnnotations([mapObject as GeoBaseEntityPointAnnotation], animated: true)

            }
            else if (mapObject is MKPolyline){
                mapView.addOverlay(mapObject as MKPolyline);
            }
            
        }

}

class GeoBaseEntityStyledMkPolylineAnnotation:MKPolyline{
    var imageName: String!
    var callOutLeftImageName: String!
    var shouldShowCallout = false
    var geoBaseEntity: GeoBaseEntity

    override init() {
