use_tool_with_selected_objects<ElevateTool>();
else if(key==Msp::Input::KEY_ESC)
{
- if(cur_tool)
- {
- delete cur_tool;
- cur_tool = 0;
- }
- else if(mode==CATALOGUE)
+ if(mode==CATALOGUE)
mode = SELECT;
- else
+ else if(mode==SELECT)
selection.clear();
}
else if(key==Msp::Input::KEY_X)
template<typename T>
T *Designer::use_tool_with_selected_objects()
{
- T *tool = new T(*this, mouse, selection.get_objects());
+ T *tool = new T(*this, keyboard, mouse, selection.get_objects());
use_tool(tool);
return tool;
}
template<typename T>
T *Designer::use_tool()
{
- T *tool = new T(*this, mouse);
+ T *tool = new T(*this, keyboard, mouse);
use_tool(tool);
return tool;
}
}
cur_tool = tool;
- cur_tool->signal_status.connect(sigc::mem_fun(this, &Designer::manipulation_status));
- manipulation_status(cur_tool->get_status());
+ cur_tool->signal_status.connect(sigc::mem_fun(this, &Designer::tool_status));
+ tool_status(cur_tool->get_status());
mode = TOOL;
}
}
}
-void Designer::manipulation_status(const string &status)
+void Designer::tool_status(const string &status)
{
lbl_status->set_text(status);
}
-void Designer::measure_done()
-{
- mode = SELECT;
- selection_changed();
-}
-
void Designer::track_properties_response(int)
{
const set<Track *> &tracks = selection.get_objects<Track>();