Support POI selection as well as way selection

This commit is contained in:
Tom MacWright
2012-10-26 18:36:32 -04:00
parent 5d41ce8c9b
commit 18f2b21839
2 changed files with 4 additions and 3 deletions

View File

@@ -3,7 +3,7 @@ image.tile {
}
/* base styles */
use, path {
path, image.marker {
fill: none;
cursor: pointer;
}

View File

@@ -230,7 +230,7 @@ iD.Map = function(obj) {
var _id = selection[0];
var active_entity = all.filter(function(a) {
return a._id === _id;
return a._id === _id && a.entityType === 'way';
});
var handles = layers[0].hit.selectAll('circle.handle')
@@ -260,7 +260,8 @@ iD.Map = function(obj) {
.attr('d', nodeline)
.attr('class', classes('stroke'));
markers.enter().append('image');
markers.enter().append('image')
.on('click', selectClick);
markers.attr('class', classes('marker'))
.attr({ width: 16, height: 16 })
.attr('xlink:href', markerimage)