Diff of /trunk/src/map.c

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

revision 177 by harbaum, Wed Jun 10 12:07:11 2009 UTC revision 180 by harbaum, Thu Jun 18 18:40:44 2009 UTC
# Line 1374  static void map_touchnode_update(appdata Line 1374  static void map_touchnode_update(appdata
1374      /* don't highlight the dragged node itself and don't highlight */      /* don't highlight the dragged node itself and don't highlight */
1375      /* deleted ones */      /* deleted ones */
1376      if((node != cur_node) && (!(node->flags & OSM_FLAG_DELETED))) {      if((node != cur_node) && (!(node->flags & OSM_FLAG_DELETED))) {
1377        gint nx = x - node->lpos.x;        gint nx = abs(x - node->lpos.x);
1378        gint ny = y - node->lpos.y;        gint ny = abs(y - node->lpos.y);
1379    
1380        if((nx < map->style->node.radius) && (ny < map->style->node.radius) &&        if((nx < map->style->node.radius) && (ny < map->style->node.radius) &&
1381           (nx*nx + ny*ny < map->style->node.radius * map->style->node.radius))           (nx*nx + ny*ny < map->style->node.radius * map->style->node.radius))
# Line 1389  static void map_touchnode_update(appdata Line 1389  static void map_touchnode_update(appdata
1389    if(!map->touchnode && map->action.way) {    if(!map->touchnode && map->action.way) {
1390      node_chain_t *chain = map->action.way->node_chain;      node_chain_t *chain = map->action.way->node_chain;
1391      while(!map->touchnode && chain && chain->next) {      while(!map->touchnode && chain && chain->next) {
1392        gint nx = x - chain->node->lpos.x;        gint nx = abs(x - chain->node->lpos.x);
1393        gint ny = y - chain->node->lpos.y;        gint ny = abs(y - chain->node->lpos.y);
1394    
1395        if((nx < map->style->node.radius) && (ny < map->style->node.radius) &&        if((nx < map->style->node.radius) && (ny < map->style->node.radius) &&
1396           (nx*nx + ny*ny < map->style->node.radius * map->style->node.radius))           (nx*nx + ny*ny < map->style->node.radius * map->style->node.radius))

Legend:
Removed from v.177  
changed lines
  Added in v.180