From: Mikko Rasa Date: Sat, 24 Aug 2013 07:48:34 +0000 (+0300) Subject: Fix some bugs in tools X-Git-Url: http://git.tdb.fi/?a=commitdiff_plain;h=67785b72b333d539f779343ea674400e923c328e;p=r2c2.git Fix some bugs in tools --- diff --git a/source/designer/extendtool.cpp b/source/designer/extendtool.cpp index aa0f723..e35b4ab 100644 --- a/source/designer/extendtool.cpp +++ b/source/designer/extendtool.cpp @@ -244,5 +244,6 @@ vector ExtendTool::create_straight(const Vector &start, const Angle &di void ExtendTool::update_selection(Selection &sel) const { - sel.replace(extend_tracks.begin(), extend_tracks.end()); + if(accepted) + sel.replace(extend_tracks.begin(), extend_tracks.end()); } diff --git a/source/designer/slopetool.cpp b/source/designer/slopetool.cpp index 0f6990e..869724e 100644 --- a/source/designer/slopetool.cpp +++ b/source/designer/slopetool.cpp @@ -13,6 +13,7 @@ SlopeTool::SlopeTool(Designer &d, Input::Mouse &m, const set &objects) if(!dynamic_cast(*i) || (*i)->get_n_link_slots()!=2) { set_status("Must have linear tracks only"); + set_done(); return; }