modedit: Don't activate measure tool without a footprint

There's no risk in measuring an empty footprint but there's no benefit
either.  This matches the measure tool to the other, deactivated
footprint tools.
This commit is contained in:
Seth Hillbrand 2018-06-12 16:48:59 -07:00
parent 04706d9d02
commit fb1aa56b77
1 changed files with 3 additions and 0 deletions

View File

@ -1154,6 +1154,9 @@ int EDIT_TOOL::ExchangeFootprints( const TOOL_EVENT& aEvent )
int EDIT_TOOL::MeasureTool( const TOOL_EVENT& aEvent )
{
if( EditingModules() && !frame()->GetModel())
return 0;
auto& view = *getView();
auto& controls = *getViewControls();
int toolID = EditingModules() ? ID_MODEDIT_MEASUREMENT_TOOL : ID_PCB_MEASUREMENT_TOOL;