diff -r 9316dcc0a355 -r a222eb109e52 gui/broken_edge.cc --- a/gui/broken_edge.cc Thu Jun 16 18:08:04 2005 +0000 +++ b/gui/broken_edge.cc Thu Jun 16 18:58:15 2005 +0000 @@ -17,25 +17,42 @@ if(arrow)delete(arrow); } -void BrokenEdge::set_points(Gnome::Canvas::Points p) +void BrokenEdge::set_points(Gnome::Canvas::Points p, bool move) { bool set_arrow=false; - if(p.size()==2) + if(!move) { - set_arrow=true; - Gnome::Canvas::Points points_with_center; - points_with_center.push_back(my_points[0]=p[0]); - points_with_center.push_back(my_points[1]=Gnome::Art::Point( (p[0].get_x()+p[1].get_x())/2+0 , (p[0].get_y()+p[1].get_y())/2 )+0 ); - points_with_center.push_back(my_points[2]=p[1]); - property_points().set_value(points_with_center); - } - if(p.size()==3) + if(p.size()==2) + { + set_arrow=true; + Gnome::Canvas::Points points_with_center; + points_with_center.push_back(my_points[0]=p[0]); + points_with_center.push_back(my_points[1]=Gnome::Art::Point( (p[0].get_x()+p[1].get_x())/2+0 , (p[0].get_y()+p[1].get_y())/2 )+0 ); + points_with_center.push_back(my_points[2]=p[1]); + property_points().set_value(points_with_center); + } + if(p.size()==3) + { + set_arrow=true; + property_points().set_value(p); + for(int i=0;i<3;i++) + { + my_points[i]=p[i]; + } + } + } + else { - set_arrow=true; - property_points().set_value(p); - for(int i=0;i<3;i++) + if(p.size()==2) { - my_points[i]=p[i]; + Gnome::Canvas::Points points; + my_points[0]=p[0]; + my_points[2]=p[1]; + for(int i=0;i<3;i++) + { + points.push_back(my_points[i]); + } + property_points().set_value(points); } }