Added a handler for not implemented toolbar buttons functionality in GAL.
This commit is contained in:
parent
94cc845b3f
commit
26323007b5
|
@ -261,6 +261,10 @@ TOOL_ACTION COMMON_ACTIONS::showHelp( "pcbnew.Control.showHelp",
|
|||
AS_GLOBAL, '?',
|
||||
"", "" );
|
||||
|
||||
TOOL_ACTION COMMON_ACTIONS::toBeDone( "pcbnew.Control.toBeDone",
|
||||
AS_GLOBAL, 0, // dialog saying it is not implemented yet
|
||||
"", "" ); // so users are aware of that
|
||||
|
||||
TOOL_ACTION COMMON_ACTIONS::routerActivate( "pcbnew.InteractiveRouter",
|
||||
AS_GLOBAL, 'X',
|
||||
"Run push & shove router", "Run push & shove router", AF_ACTIVATE );
|
||||
|
@ -317,6 +321,17 @@ boost::optional<TOOL_EVENT> COMMON_ACTIONS::TranslateLegacyId( int aId )
|
|||
|
||||
case ID_ZOOM_PAGE: // toolbar button "Fit on Screen"
|
||||
return COMMON_ACTIONS::zoomFitScreen.MakeEvent();
|
||||
|
||||
case ID_PCB_DELETE_ITEM_BUTT:
|
||||
case ID_PCB_HIGHLIGHT_BUTT:
|
||||
case ID_PCB_SHOW_1_RATSNEST_BUTT:
|
||||
case ID_PCB_PLACE_OFFSET_COORD_BUTT:
|
||||
case ID_TB_OPTIONS_SHOW_MODULE_RATSNEST:
|
||||
case ID_TB_OPTIONS_SELECT_CURSOR:
|
||||
case ID_TB_OPTIONS_SHOW_EXTRA_VERTICAL_TOOLBAR_MICROWAVE:
|
||||
case ID_MENU_PCB_SHOW_HIDE_MUWAVE_TOOLBAR:
|
||||
case ID_MICROWAVE_V_TOOLBAR:
|
||||
return COMMON_ACTIONS::toBeDone.MakeEvent();
|
||||
}
|
||||
|
||||
return boost::optional<TOOL_EVENT>();
|
||||
|
|
|
@ -148,6 +148,7 @@ public:
|
|||
static TOOL_ACTION resetCoords;
|
||||
static TOOL_ACTION switchUnits;
|
||||
static TOOL_ACTION showHelp;
|
||||
static TOOL_ACTION toBeDone;
|
||||
|
||||
/**
|
||||
* Function TranslateLegacyId()
|
||||
|
|
|
@ -506,6 +506,15 @@ int PCBNEW_CONTROL::ShowHelp( TOOL_EVENT& aEvent )
|
|||
}
|
||||
|
||||
|
||||
int PCBNEW_CONTROL::ToBeDone( TOOL_EVENT& aEvent )
|
||||
{
|
||||
DisplayInfoMessage( m_frame, _( "Not implemented yet." ) );
|
||||
setTransitions();
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
void PCBNEW_CONTROL::setTransitions()
|
||||
{
|
||||
// View controls
|
||||
|
@ -549,4 +558,5 @@ void PCBNEW_CONTROL::setTransitions()
|
|||
Go( &PCBNEW_CONTROL::ResetCoords, COMMON_ACTIONS::resetCoords.MakeEvent() );
|
||||
Go( &PCBNEW_CONTROL::SwitchUnits, COMMON_ACTIONS::switchUnits.MakeEvent() );
|
||||
Go( &PCBNEW_CONTROL::ShowHelp, COMMON_ACTIONS::showHelp.MakeEvent() );
|
||||
Go( &PCBNEW_CONTROL::ToBeDone, COMMON_ACTIONS::toBeDone.MakeEvent() );
|
||||
}
|
||||
|
|
|
@ -91,6 +91,7 @@ public:
|
|||
int ResetCoords( TOOL_EVENT& aEvent );
|
||||
int SwitchUnits( TOOL_EVENT& aEvent );
|
||||
int ShowHelp( TOOL_EVENT& aEvent );
|
||||
int ToBeDone( TOOL_EVENT& aEvent );
|
||||
|
||||
private:
|
||||
///> Sets up handlers for various events.
|
||||
|
|
Loading…
Reference in New Issue