Diff of /trunk/src/map_edit.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 14 by achadwick, Thu Dec 11 13:26:13 2008 UTC revision 15 by harbaum, Tue Dec 16 17:00:20 2008 UTC
# Line 396  void map_edit_way_node_add_highlight(map Line 396  void map_edit_way_node_add_highlight(map
396    if(map_item_is_selected_way(map, item)) {    if(map_item_is_selected_way(map, item)) {
397      gint nx, ny;      gint nx, ny;
398      canvas_window2world(map->canvas, x, y, &nx, &ny);      canvas_window2world(map->canvas, x, y, &nx, &ny);
399      if(canvas_item_get_segment(item->item, nx, ny) >= 0)      if(canvas_item_get_segment(item->item, nx, ny) >= 0)
400        map_hl_cursor_draw(map, x, y, FALSE, map->style->node.radius);        map_hl_cursor_draw(map, x, y, FALSE, map->style->node.radius);
401    }    }
402  }  }
403    
404  void map_edit_way_node_add(map_t *map, gint x, gint y) {  void map_edit_way_node_add(map_t *map, gint x, gint y) {
405    /* check if we are still hovering above the selected way */    /* check if we are still hovering above the selected way */
406    map_item_t *item = map_item_at(map, x, y);    map_item_t *item = map_real_item_at(map, x, y);
407    if(item && map_item_is_selected_way(map, item)) {    if(item && map_item_is_selected_way(map, item)) {
408      /* convert mouse position to canvas (world) position */      /* convert mouse position to canvas (world) position */
409      canvas_window2world(map->canvas, x, y, &x, &y);      canvas_window2world(map->canvas, x, y, &x, &y);
# Line 486  void map_edit_way_cut_highlight(map_t *m Line 486  void map_edit_way_cut_highlight(map_t *m
486  void map_edit_way_cut(map_t *map, gint x, gint y) {  void map_edit_way_cut(map_t *map, gint x, gint y) {
487    
488    /* check if we are still hovering above the selected way */    /* check if we are still hovering above the selected way */
489    map_item_t *item = map_item_at(map, x, y);    map_item_t *item = map_real_item_at(map, x, y);
490    if(item && (map_item_is_selected_way(map, item) ||    if(item && (map_item_is_selected_way(map, item) ||
491                map_item_is_selected_node(map, item))) {                map_item_is_selected_node(map, item))) {
492      gboolean cut_at_node = map_item_is_selected_node(map, item);      gboolean cut_at_node = map_item_is_selected_node(map, item);

Legend:
Removed from v.14  
changed lines
  Added in v.15