diff -r 7a32d528857f -r 1b8e20c04704 graph_displayer_canvas-event.cc --- a/graph_displayer_canvas-event.cc Tue Aug 23 15:57:12 2005 +0000 +++ b/graph_displayer_canvas-event.cc Tue Aug 23 16:27:59 2005 +0000 @@ -564,7 +564,8 @@ Edge clicked_edge=INVALID; //find the activated item between texts - active_item=(get_item_at(e->button.x, e->button.y)); + window_to_world (e->button.x, e->button.y, clicked_x, clicked_y); + active_item=(get_item_at(clicked_x, clicked_y)); for (EdgeIt i(mapstorage.graph); i!=INVALID; ++i) { if(edgetextmap[i]==active_item) @@ -576,9 +577,6 @@ //if it was not between texts, search for it between edges if(clicked_edge==INVALID) { - window_to_world (e->button.x, e->button.y, clicked_x, clicked_y); - active_item=(get_item_at(clicked_x, clicked_y)); - for (EdgeIt i(mapstorage.graph); i!=INVALID; ++i) { //at the same time only one can be active @@ -592,7 +590,8 @@ if(clicked_edge!=INVALID) { // the id map is not editable - if (nodemap_to_edit == "id") return 0; + if (edgemap_to_edit == "id") return 0; + //If there is already edited edge, it has to be saved first if(entrywidget.is_visible()) {