properly remove markers when removing a place
This commit is contained in:
parent
a48113684d
commit
ca905a54bb
2 changed files with 6 additions and 4 deletions
|
@ -217,15 +217,16 @@ Ox.ListMap = function(options, self) {
|
|||
items: [
|
||||
{id: 'all', title: 'Find: All'},
|
||||
{id: 'name', title: 'Find: Name'},
|
||||
{id: 'geoname', title: 'Find: Geoname'},
|
||||
{id: 'country', title: 'Find: Country'}
|
||||
{id: 'alternativeNames', title: 'Find: Alternative Names'},
|
||||
{id: 'geoname', title: 'Find: Geoname'}
|
||||
],
|
||||
overlap: 'right',
|
||||
width: 128
|
||||
type: 'image'
|
||||
}),
|
||||
self.$findInput = Ox.Input({
|
||||
clear: true,
|
||||
width: 192
|
||||
placeholder: 'Find in List',
|
||||
width: 234
|
||||
})
|
||||
]
|
||||
})
|
||||
|
|
|
@ -828,6 +828,7 @@ Ox.Map = function(options, self) {
|
|||
self.options.selected = place.id;
|
||||
//Ox.print('removePlace', Ox.getObjectById(self.places, place.id))
|
||||
self.places.splice(Ox.getPositionById(self.places, place.id), 1);
|
||||
self.resultPlace && self.resultPlace.remove();
|
||||
self.resultPlace = place;
|
||||
place.marker.update();
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue